Delete an account email report

Overview

Stop a scheduled email report for an account user.

Use this when the report is no longer wanted.

You'll need the report_id.

The report stops.

Prerequisites

  • An Account bearer token. See Authentication.
  • The report_id of the report you want to delete, from List scheduled reports. The report must belong to your own account or an account beneath it in your hierarchy.

Base URL

EnvironmentURL
Productionhttps://production-api.shoutaboutus.com
Developmenthttps://development-api.shoutaboutus.com

Endpoint

DELETE /api/v1/user/reports/delete

Authentication

Account token

  • Only Account tokens can call it. Any other token gets 403 (This action is unauthorized.).
  • The report named in report_id must belong to your own account or to an account beneath it in your hierarchy. A report outside it is rejected with 422.

Rate limit

This endpoint has no rate limit.

Request parameters

None.

Request body

Send the report to delete as JSON in the request body.

FieldTypeRequiredDescription
report_idintegerYesThe report to delete. Must exist and be within your account hierarchy.

Request payload

{
  "report_id": 42
}

Response body

The payload is inside data.

FieldTypeDescription
statusstringsuccess.
responsestringThe confirmation message, Report has been deleted successfully!.

Response payload

{
  "data": {
    "status": "success",
    "response": "Report has been deleted successfully!"
  }
}

Examples

Success payload

See Response payload.

Error payload

403 Not an Account token

{
  "message": "This action is unauthorized."
}

422 Report doesn't exist or is outside your tree

{
  "message": "The selected report id is invalid. (and 1 more error)",
  "errors": {
    "report_id": [
      "The selected report id is invalid.",
      "The selected report id does not belong to your company hierarchy."
    ]
  }
}

500 Report already deleted

The report was already deleted:

{
  "message": "An unexpected error occurred. Please try again later or contact your account rep.",
  "status": "error",
  "errors": []
}
StatusMeaning
200The report is deleted.
401The token is missing, expired or invalid.
403The token isn't an Account token.
422report_id is missing, or the report doesn't exist or is outside your account.
500The report was already deleted, or an unexpected server error.

Example request

curl --request DELETE \
  --url "https://production-api.shoutaboutus.com/api/v1/user/reports/delete" \
  --header 'Authorization: Bearer <bearer-token>' \
  --header 'Accept: application/json' \
  --header 'Content-Type: application/json' \
  --data '{"report_id": 42}'

Did this page help you?