Skip to Content
Uptimeify Docs
Organization

Apply Report Default

Writes a package's monthlyReportsDefault onto every existing customer currently on that package, once.

POST /api/package-configs/:packageType/apply-report-default

The organization comes from your session or API token. The path POST /api/organizations/:id/package-configs/:packageType/apply-report-default does the same for the organization :id; it is deprecated and removed on 2027-01-18.

Upsert Package Config's monthlyReportsDefault is a template: it only seeds monthlyReportsEnabled for customers created from then on. Saving the package config never rewrites customers who already exist on it, on purpose, a configuration save must not silently mutate customer rows. This endpoint is the explicit, one-off action for the other case: propagate the package's current monthlyReportsDefault onto every customer that already holds that package, right now.

This is a single bulk UPDATE, not a loop with per-customer error isolation like Bulk Actions: it writes one boolean column with no cascade and no side effects, so per-row isolation buys nothing here. Either the whole set is written, or the request fails before anything is written.

Query parameter organizationId (global admins)

organizationId (positive integer, optional): apply the default in this organization instead of your own. Only global admins may name a foreign organization; anyone else gets 403 forbidden. Naming your own organization behaves like leaving the parameter out. This is the successor for the organization :id of the deprecated path.

Path parameter :id (deprecated path only)

:id is the organization's numeric id, the same integer id field returned by Get Organization Details. This is narrower than the sibling package-config routes, which also resolve :organizationPublicId (a UUID). This endpoint does not: it parses the path segment with Number(...) directly and rejects anything that is not a positive integer with 400 invalidRequestBody.

Example (cURL)

BASE_URL="https://uptimeify.io"
TOKEN="<your-api-token>"

curl -X POST "$BASE_URL/api/package-configs/pro/apply-report-default" \
  -H "Authorization: Bearer $TOKEN" \
  -H "Accept: application/json"

No request body.

Response

{ "updated": 42 }

updated is the number of customer rows written. A customer "holds" the package if its packageId matches this package config's id, or, for customers that were never assigned an id, if its packageType string matches. Customers that only happen to share the same packageType string without holding this exact config are not included.

Common errors

  • 400 invalidRequestBody :id is not a positive integer, or :packageType is missing
  • 400 invalidOrganizationId organizationId is not a positive integer
  • 400 organizationIdRequired the session or token has no organization (path without :id)
  • 401 unauthorized you are not logged in
  • 403 forbidden you are not an admin of this organization and not a global admin
  • 403 customerScopedTokenForbidden when called with a customer-scoped API token; this is an organization-wide action and requires an organization-scoped token or a session
  • 404 notFound no package config with this packageType exists for this organization

Authorization note:

  • Write access is required (organization admin of the target organization, or global admin).
  • A customer-scoped API token is refused outright. This endpoint writes across every customer holding the package, so there is no customer dimension to narrow it down to; a token bound to a single customer must not reach the rest of the organization.

On this page