zenly/Documentação
Buscar na documentação
Português
API referenceCatalog

Get a plan

GET/v1/plans/{id}
Authorization

Any active key, sent as a bearer token. Keys are owner-equivalent, so there are no scopes to grant and nothing to configure per endpoint. See Authentication.

Parameters
idstring (uuid)pathREQUIRED

Edit any field above and the request updates as you type. Empty fields are left out.

Response fields
allLocationsboolean

When true the plan sells at every location and locationIds is empty

billingIntervalstring (enum)OPTIONAL

How often it charges. Present only for recurring plans.

billingKindstring (enum)
createdAtstring (date-time)
currencystring
durationCountinteger (int32)OPTIONAL
durationUnitstring (enum)OPTIONAL
entitlementsarray of PlanEntitlementBody
6 fields per item
creditQuantityinteger (int32)OPTIONAL

Credits granted at signup. Present only for type=credits.

maxVisitsPerPeriodinteger (int32)OPTIONAL

Visit cap within each period. Present only for a capped access grant.

periodstring (enum)OPTIONAL
serviceGroupIdstringOPTIONAL
serviceTypeIdstringOPTIONAL
typestring (enum)
idstring
isTrialboolean

An entry product, sellable once to a client with no contract history

locationIdsarray of string
namestring
priceCentsinteger (int64)

Integer minor units of currency, never a decimal

statusstring (enum)
termsstringOPTIONAL

The agreement snapshotted onto a contract at signup

updatedAtstring (date-time)
Errors

These apply to every endpoint on the API, not just this one. Errors covers the body shape.

401
Unauthorized

No bearer token, or a token that is unknown, revoked or expired. All four answer identically on purpose, so a caller probing tokens learns nothing about which is which.

402
Payment Required

The organization’s plan does not include the public API. It is available on Pro and above, and the check runs on every request, so a downgrade stops keys that were minted earlier.

403
Forbidden

The organization is not active.

429
Too Many Requests

The key is over its rate limit. Back off and retry.

500
Internal Server Error

Something failed on our side. The body carries a short sentence and never an internal error string, so quote your own request timestamp when reporting one.

stays in this tab
cURL
curl "https://api.zenly.app.br/v1/plans/019f9a89-62bf-750a-bdc0-375919dea60a" \
  -H "Authorization: Bearer $ZENLY_API_KEY"
Response200 OK
{
  "allLocations": false,
  "billingInterval": "week",
  "billingKind": "recurring",
  "createdAt": "2026-01-31T09:00:00Z",
  "currency": "string",
  "durationCount": 0,
  "durationUnit": "day",
  "entitlements": [
    {
      "creditQuantity": 0,
      "maxVisitsPerPeriod": 0,
      "period": "day",
      "serviceGroupId": "string",
      "serviceTypeId": "string",
      "type": "access"
    }
  ],
  "id": "string",
  "isTrial": false,
  "locationIds": [
    "string"
  ],
  "name": "string",
  "priceCents": 0,
  "status": "active",
  "terms": "string",
  "updatedAt": "2026-01-31T09:00:00Z"
}