Skip to content

Describe the calling key

GET
/commerce/management/v1/whoami
curl --request GET \
--url https://api.ebitex.io/commerce/management/v1/whoami \
--header 'Authorization: Bearer <token>'

Reports what the Commerce management key you are calling with is: the organization it belongs to, its own id and name, and its scopes.

Call it from your own server with a management key (the Management keys section of Commerce’s delivery keys screen); it has no CORS policy, so a browser page cannot use it. The key belongs to the organization and works on every store’s orders. It has two tiers: commerce.management.read reads orders, finds a shipment by its carrier reference and reads an order’s fulfilment; commerce.orders.fulfil does all of that and also records and updates shipments. Neither can refund, cancel, move an order along, change stock, or read who bought: no answer carries a buyer’s name, email or address. The key’s budget is 300 requests a minute.

Key: any valid Commerce management key, whatever its scopes.

{ "organizationId", "organizationName", "organizationSlug", "keyId", "keyName", "scopes": [ … ] }. scopes is sorted.

missing_api_key or invalid_api_key: no key was sent, or it is unknown, revoked or expired.

payment_required: the organization’s subscription needs attention.

scope_denied: the key lacks commerce.orders.fulfil. app_not_available: Commerce is not enabled for the organization. ip_denied: the key was used from an address outside its restrictions.

rate_limited: the key spent its 300 requests a minute; Retry-After says how long to wait. too_many_failed_authentications: too many bad keys from this address.