Skip to content
This repository has been archived by the owner on Jun 27, 2024. It is now read-only.

Latest commit

 

History

History
76 lines (59 loc) · 1.92 KB

File metadata and controls

76 lines (59 loc) · 1.92 KB
description
Deletes an invite from the server.

Delete invite by id

{% hint style="info" %} Requires the create-invite-links permission. {% endhint %}

URL Requires Auth HTTP Method
api/v1/removeInvite/:_id YES DELETE

Headers

Argument Example Required Description
X-User-Id myuser-name Required Your username hash (returned after you log in through the API)
X-Auth-Token myauth-token Required Your token (returned after you log in through the API)

Path Parameters

Argument Example Required Description
_id 'kDKQ3H' Required The id of the invite to be deleted.

Example Call

curl --location --request DELETE 'http://localhost:3000/api/v1/removeInvite/:_id\
--header 'X-Auth-Token: myauth-token' \
--header 'X-User-Id: myuser-name'
 -d "customUserStatusId=EscbQinc8jmeXbpt7"

Result

Success

{
    "success": true
}

Errors

Any of the following errors can occur upon the endpoint.

  • Authorization: Requires an authentication token for the request to be made.
  • Invalid Invitation Id: Requires a valid invitation _id

{% tabs %} {% tab title=" Authorization" %}

{
    "success": false,
    "error": "unauthorized"
}

{% endtab %}

{% tab title="Invalid Invitation Id" %}

{
    "success": false,
    "error": "Invalid Invitation _id [invalid-invitation-id]",
    "errorType": "invalid-invitation-id",
    "details": {
        "method": "removeInvite"
    }
}

{% endtab %} {% endtabs %}