Skip to content
Navigation

Cancel a staff invitation

DELETE
https://api.nicer.travel/identity/{userId}/invite/{inviteId}

Cancels a pending staff invitation of the acting agency and frees its email and phone lookup rows when nothing else uses them. An admin cancels any of the agency's; anyone else only one they sent. Answers the invitation as it was.

Authorization

  • bearerAuth
    HTTP Bearer (JWT)
    required

    Authorization: Bearer <token>

Path parameters

  • userId
    string
    required
  • inviteId
    string
    required

Returns

200

OK

JSON
  • companyName
    string
    required

    The agency the invitation is to.

  • createdBy
    string
    required

    The user id of whoever sent it, or SYSTEM for a paid Join.

  • invitedBy
    string
    required

    The user id of whoever sent it, or SYSTEM for a paid Join.

  • lastModifiedBy
    string
    required

    The user id of whoever last changed it, or SYSTEM.

  • role
    advisor
    or
    traveler
    or
    admin
    or
    superadmin
    required

    The role the invitee gets on accepting.

  • inviteId
    string
    required

    The invitation's id.

  • userId
    string
    required

    The user id of whoever sent it; JOIN#<registrationId> for a paid Join.

  • createdAt
    string
    required

    When it was sent.

  • type
    string
    required
  • updatedAt
    string
    required

    When it last changed.

  • advisorId
    optional

    The advisor some older invitations name.

    Any of the following:

    • string
    • null
  • deleted
    optional
    boolean

    True once it was cancelled.

  • email
    optional
    string

    The email it was sent to.

  • expiresAt
    optional
    string

    When it can no longer be accepted; one without it expires seven days after createdAt.

  • familyName
    optional
    string

    The invitee's last name.

  • fullName
    optional
    string

    The invitee's first and last name, joined.

  • givenName
    optional
    string

    The invitee's first name.

  • metadata
    optional
    map of
    string

    Details stored with it, such as joinRegistrationId.

  • phoneNumber
    optional
    string

    The phone it was sent to.

  • resendCount
    optional
    number

    How many times it was sent again; four at most.

  • sendMessage
    optional
    boolean

    Whether the request asked to send it, kept on invitations of a person whose traveler account was opened from a staff invitation.

400

Request failed. errorCode is stable; errorMessage is for humans.
JSON
  • errorCode
    string
    required
  • errorMessage
    string
    required

401

Request failed. errorCode is stable; errorMessage is for humans.
JSON
  • errorCode
    string
    required
  • errorMessage
    string
    required

403

Request failed. errorCode is stable; errorMessage is for humans.
JSON
  • errorCode
    string
    required
  • errorMessage
    string
    required

Type to search…

↑↓ navigate↵ selectEsc close