{
  "schemaVersion": 2,
  "apiVersion": "v1",
  "baseUrl": "https://msghop.com",
  "principals": {
    "anonymous": "No credential; limited to documented session, recovery, health, readiness, and release operations",
    "user": "Short-lived MessageHop user access token with current Organization membership",
    "registeredApp": "Scoped MessageHop server credential"
  },
  "routes": {
    "sessions": "/v1/sessions",
    "sessionRefresh": "/v1/sessions/refresh",
    "passwordRecovery": "/v1/password-recovery",
    "customerControl": "/v1/control/{operation}",
    "authorizationCheck": "/v1/auth/check",
    "messages": "/v1/messages",
    "message": "/v1/messages/{messageId}",
    "balances": "/v1/balances",
    "usage": "/v1/usage"
  },
  "operations": {
    "session": [
      "createSession",
      "refreshSession",
      "requestPasswordRecovery"
    ],
    "registeredApp": [
      "checkAuthorization",
      "sendMessage",
      "getMessage",
      "getBalance",
      "listUsage"
    ],
    "customerControl": [
      "acceptOrganizationInvitation",
      "appendCustomerSupportReply",
      "closeChat",
      "createChatRequest",
      "createOrganization",
      "createServerCredential",
      "createSupportTicket",
      "escalateChatToTicket",
      "generateAttachmentUploadUrl",
      "getClientReleasePolicy",
      "getCustomerBalance",
      "getCustomerContext",
      "getCustomerSupportTicket",
      "getPlatformConfig",
      "getTicketAttachmentDownloadUrl",
      "inviteOrganizationMember",
      "listChatMessages",
      "listCustomerBillingActivity",
      "listCustomerMessageHistory",
      "listCustomerSupportTickets",
      "listOrganizationBudgets",
      "listOrganizationMembers",
      "listServerCredentials",
      "registerApp",
      "registerTicketAttachment",
      "revokeOrganizationMember",
      "revokeServerCredential",
      "rotateServerCredential",
      "saveOrganizationBudget",
      "sendChatMessage"
    ]
  },
  "rules": {
    "customerControlMethod": "POST",
    "customerControlBody": "Direct JSON object",
    "crossPrincipalDelegation": false,
    "rawSecretsReturnedOnlyByShowOnceContracts": true,
    "moneyUnit": "integer minor units with explicit currency",
    "implementationProvidersAreNotPartOfTheContract": true
  }
}
