Edit partner email report

Overview

Update an existing partner email report's frequency and account targeting; report type and recipient are not changed here.

Prerequisites

  • A bearer token. Callable with Partner tokens.

Base URL

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

Endpoint

POST /api/v1/partner/reports/edit

Authentication

  • Requires a bearer token in the Authorization: Bearer <bearer-token> header.

  • Who can call it: Partner tokens.

  • Mounted under the partner/* group (partner-admin scope, no Hipages gate).

  • Targeting must sit inside your own account tree, keyed on each account.* id (must be a company within the partner's own tree).

  • The presence of report_id switches into edit-mode rules (report existence + period validated, recipient fields not required).

Rate limit

  • No rate limit.

Request body

  • Body:
FieldTypeRequiredDescription
report_idintegeryesMust exist in reports. Required to enter edit branch.
reportPeriodTypestringyesday, week, or month; validated against the existing report.
all_accountintegeryes1 = all accounts, 0 = specific accounts. Rule required|nullable|in:0,1.
accountint[]required_if all_account=0Account company ids; each must exist and pass an ownership check. Existing report_companies rows get deleted, then re-inserted.
{
  "report_id": 5,
  "reportPeriodType": "week",
  "all_account": 0,
  "account": [
    10,
    11
  ]
}

Response

  • data.status (string) — success.
  • data.response (string) — message Report has been updated successfully!.

200 Success · 200

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

Errors

StatusMeaning
401The bearer token is missing, expired or invalid
422The request failed validation — the response names the fields
500Unexpected server error

Example request

curl --request POST \
  --url "https://production-api.shoutaboutus.com/api/v1/partner/reports/edit" \
  --header 'Authorization: Bearer <bearer-token>' \
  --header 'Accept: application/json' \
  --header 'Content-Type: application/json' \
  --data '{"report_id": 5, "reportPeriodType": "week", "all_account": 0, "account": [10, 11]}'

Did this page help you?