Get a secret

SDK platic.secrets.get()

Retrieves the secret’s details and current authorizations in usedBy. Check them before revoking or deleting the secret to see which resources will stop working.

Example

await platic.secrets.get("secret_123");

Path parameters

ParameterTypeDescriptionRequired
secretIdstringId of the secret✓

Response

{
  "status": "success",
  "data": {
    "id": "5d0c7a1e9b3f4a6c8e2d1f0b7a9c3e5d6f8a0b2c4d6e8f1a3b5c7d9e0f2a4b6c",
    "name": "Acme Store · Orders API",
    "kind": "bearer",
    "status": "active",
    "revision": 1,
    "createdAt": "2026-10-28T12:05:00.000Z",
    "updatedAt": "2026-10-28T12:05:00.000Z",
    "usedBy": [
      {
        "kind": "api",
        "id": "RuzoaswTBBrhutHyKYZn",
        "slot": "auth.token",
        "destination": "https://api.acme.example"
      }
    ]
  }
}

Response fields

FieldTypeDescription
idstringId of the secret
namestringName to recognize it
kindstringapi_key, bearer, password, or signing_key
statusstringactive, revoked, or deleting. See secret states
revisionnumberGoes up with every change to the secret
createdAt, updatedAtstring | nullDates in ISO 8601
expiresAtstringWhen it stops working. Only appears if it has an expiration
usedByarrayThe secret's current authorizations. Empty if it is not bound to anything
usedBy[].kindstringType of resource: api, mcp, webhook, or app (an application installed from Platica)
usedBy[].idstringId of the resource: the integrationId, the mcpId, or the webhookId
usedBy[].slotstringThe slot it is bound to
usedBy[].destinationstringThe origin Platica may send the value to

Errors

Statusdetails.codeWhen it happens
403FORBIDDENThe person behind the token cannot view secrets
404SECRET_NOT_FOUNDThe secret does not exist in this workspace or was already deleted

Notes

  • usedBy leaves out revoked authorizations and checks at most 50.
  • Check each slot’s state in the resource’s secrets[]. An authorization can appear in usedBy while the slot is in needs_authorization if the resource changed afterwards.
  • To change the value without touching what already uses it, rotate the secret.
  • A secret that was already deleted answers 404, the same as one that never existed.