Manually decline an ambassador (manager)

PATCH /manager/ambassadors/{id}/decline

Path parameters

  • id integer Required

    The ambassador id

Query parameters

  • if set , the preview of the mail sent to the ambassador will be returned , no mail will be sent

application/json

Body

  • reason string

    The reason of the decline

Responses

  • 200 application/json

    success

    One of:

    HTML preview of the mail sent to the ambassador, only returned if parameter preview-mail is set in the query

  • 401 application/json

    Unauthorized.

    Hide response attribute Show response attribute object
  • Forbidden - You don't have permission to access this route

  • Not found - The ambassador does not exist

  • 422 application/json

    Unprocessable Content

    Hide response attributes Show response attributes object
    • message string

      Error message.

    • errors object
      Hide errors attributes Show errors attributes object
      • field array[string]

        Error message details.

      • * array[string] Additional properties

        Error message details.

PATCH /manager/ambassadors/{id}/decline
curl \
 -X PATCH https://domain.tld/api/v2/manager/ambassadors/{id}/decline \
 -H "Authorization: Bearer $ACCESS_TOKEN" \
 -H "Content-Type: application/json" \
 -d '{"reason":"Your account has been declined because you think pineapple belongs on pizza"}'
Request examples
{
  "reason": "Your account has been declined because you think pineapple belongs on pizza"
}
Response examples (200)
{
  "message": "Ambassador declined successfully"
}
<html><body><h1>Preview</h1></body></html>
Response examples (401)
{
  "message": "Unauthorized."
}
Response examples (422)
{
  "message": "field is required! (and 3 more error)",
  "errors": {
    "field": [
      "Error message details here"
    ],
    "additionalProperty1": [
      "Error message details here"
    ],
    "additionalProperty2": [
      "Error message details here"
    ]
  }
}