Skip to main content
About this page · Updated 2026-10-22 15:05 UTC

What this page is: Step by step from no credentials to a proven first call to the Motorical Public API, then on to the endpoint you need.

How far to trust this page: the build checked 1 names, paths, tools, scopes and error codes against the real product (0 do not match). Not yet reviewed claim by claim.

Updated 2026-10-22 15:05 UTCRecently updated pages

Connect to the API

What you are looking at: the shortest path from "I have a Motorical account" to "my first API call worked, and I can prove it". Follow the steps in order, copy each command, and when step 5 shows your account you are connected. The table at the bottom lists every API call in this reference, so you can then jump to the one you need.

This page covers the Public API (logs, analytics, domains, webhooks, exports and account state). To send email see Send Email: connect; for campaigns see Marketing Communications Block: connect.

1. Create an Account API key​

  1. In the Motorical dashboard open Settings → API Access.
  2. Open the Account API Keys section and choose Create API Key.
  3. Copy the full key when it is shown. It looks like ak_live_…. A masked value in the list is not usable for API calls.

2. Find your Motor Block ID​

Still on Settings → API Access, select your Motor Block in the selector. The page shows its Motor Block ID with a copy button.

3. Put both values in your shell​

export AK_API_KEY="ak_live_YOUR_KEY"
export MOTOR_BLOCK_ID="YOUR_MOTOR_BLOCK_ID"

Keep the key out of source code, screenshots and support messages.

4. Exchange the key for a short-lived token​

The Public API takes a short-lived bearer token. This command mints one and stores it:

export MOTORICAL_TOKEN=$(curl -sS -X POST https://api.motorical.com/api/public/token/account-key \
-H "Authorization: ApiKey $AK_API_KEY" \
-H "Content-Type: application/json" \
-d "{\"motorBlockId\": \"$MOTOR_BLOCK_ID\", \"scopes\": [\"config.read\"], \"ttlSeconds\": 300}" \
| jq -r .data.token)

The token expires after ttlSeconds; run the command again when it does.

5. Prove it works​

curl -sS https://api.motorical.com/api/public/v1/account/whoami \
-H "Authorization: Bearer $MOTORICAL_TOKEN" | jq .

You are connected when the response has "success": true and shows your account and plan.

If it does not work​

You seeMeaningWhat to do
401 on step 4The key is wrong, masked, or not an Account API keyCreate a new Account API key and copy the whole value. A mk_live_… Motor Block key does not work here.
404 Motor block not foundThe ID does not belong to this accountCopy the ID again from Settings → API Access.
No valid scopes requestedYour key was created without the permission you asked forCreate a key that includes it, or ask for a narrower scope.
401 on step 5The token expired or was not storedRun step 4 again and check echo $MOTORICAL_TOKEN is not empty.

6. Move on to the calls you need​

All API calls​

These 74 calls are generated from the API definition each time the documentation is built, so the list cannot drift from the API. Type in the box to filter by method, path or description.

MethodEndpointWhat it doesScope
POST/api/auth/loginPassword login (returns JWT + refreshToken)—
POST/api/auth/refreshRotate refresh token; issue new access JWT (non-interactive)—
POST/api/auth/registerStart agent signup (email verification code)—
POST/api/auth/set-passwordSet password after email verification (returns JWT + refreshToken)—
POST/api/auth/verify-codeVerify email with 6-digit code—
POST/api/auth/web-handoffMint a one-time browser handoff URL—
GET/api/developer/sandboxGet developer sandbox status—
POST/api/developer/sandbox/convertConvert sandbox Motor Block to a verified production domain—
PATCH/api/developer/sandbox/outboundUpdate sandbox outbound lock / allowlist—
POST/api/developer/sandbox/provisionProvision unpaid developer sandbox—
POST/api/domainsAdd a customer domain—
POST/api/domains/{id}/check-dnsCheck DKIM/SPF/DMARC and persist send-readiness flags—
POST/api/domains/{id}/verifyVerify ownership and refresh DKIM/SPF send-readiness—
GET/api/oauth2/authorizeOAuth 2.0 authorization endpoint (consent HTML)—
POST/api/oauth2/tokenOAuth 2.0 token endpoint—
GET/api/oauth2/validateValidate an OAuth access token—
POST/api/public/tokenMint a Public Analytics API token with a dashboard JWT—
POST/api/public/token/account-keyMint a Public Analytics API token with an Account API Key—
GET/api/public/v1/account/authorization/motor-blocks/{id}Live grant-coverage check for one Motor Block (infrastructure)—
GET/api/public/v1/account/free-recipientsList Free-account recipients (OAuth/Public API bearer)—
POST/api/public/v1/account/free-recipientsAsk a recipient to allow test email (OAuth/Public API bearer)—
DELETE/api/public/v1/account/free-recipients/{id}Remove a Free-account recipient (OAuth/Public API bearer)—
GET/api/public/v1/account/motor-block-deletions/{jobId}Poll a permanent-deletion job—
GET/api/public/v1/account/motor-blocksList the account's production Motor Blocks (OAuth/Public API bearer)—
POST/api/public/v1/account/motor-blocksCreate a production Motor Block (OAuth/Public API bearer)—
DELETE/api/public/v1/account/motor-blocks/{id}Permanently delete a Motor Block — asynchronous and irrecoverable—
POST/api/public/v1/account/motor-blocks/{id}/assign-domainAssign a verified domain to a Motor Block—
POST/api/public/v1/account/motor-blocks/{id}/deactivateDeactivate (pause) a Motor Block — reversible—
PATCH/api/public/v1/account/motor-blocks/{id}/nameRename a Motor Block (display name only)—
POST/api/public/v1/account/motor-blocks/{id}/reactivateReactivate a deactivated Motor Block—
PATCH/api/public/v1/account/motor-blocks/{id}/typeSwitch a Motor Block between transactional and general_purpose—
GET/api/public/v1/account/rate-limitsAccount-wide rate limitsusage.read
GET/api/public/v1/account/sandboxGet account sandbox status (OAuth/Public API bearer)—
POST/api/public/v1/account/sandbox/convertConvert account sandbox to a verified production domain (OAuth/Public API bearer)—
POST/api/public/v1/account/sandbox/provisionProvision account sandbox (OAuth/Public API bearer)—
GET/api/public/v1/account/stateComposed account stateconfig.read
GET/api/public/v1/account/whoamiAccount identity, plan and grantconfig.read
GET/api/public/v1/domainsList domains on the accountconfig.read
POST/api/public/v1/domainsAdd a customer domain (account-wide, OAuth/MCP-capable)config.manage
GET/api/public/v1/domains/{id}One sending domainconfig.read
POST/api/public/v1/domains/{id}/check-dnsCheck DKIM/SPF/DMARC and persist send-readiness flags (account-wide, OAuth/MCP-capable)config.manage
GET/api/public/v1/domains/{id}/dns-recordsDNS records to publish for one domainconfig.read
GET/api/public/v1/domains/{id}/healthEmail-authentication health of one domainconfig.read
POST/api/public/v1/domains/{id}/verifyVerify ownership and refresh DKIM/SPF send-readiness (account-wide, OAuth/MCP-capable)config.manage
GET/api/public/v1/exports/{jobId}Get export job statusanalytics.read
GET/api/public/v1/exports/{jobId}/downloadDownload export file (signed token, single-use)—
GET/api/public/v1/messagesLookup message by RFC Message-ID headerlogs.read
GET/api/public/v1/messages/{id}Get message by send id (UUID)logs.read
GET/api/public/v1/messages/{id}/eventsGet message event timelinelogs.read
GET/api/public/v1/messages/{id}/recipientsPer-recipient outcomes for a multi-recipient sendlogs.read
GET/api/public/v1/motor-blocksList motor blocks bound to the tokenlogs.read
GET/api/public/v1/motor-blocks/{id}/anomaliesAnomaly detection (bounce spikes)analytics.read
GET/api/public/v1/motor-blocks/{id}/configMotor Block config snapshotconfig.read
GET/api/public/v1/motor-blocks/{id}/daily-summaryDaily summaryanalytics.read
GET/api/public/v1/motor-blocks/{id}/deliverabilityDeliverability by recipient domainanalytics.read
GET/api/public/v1/motor-blocks/{id}/domain-healthDomain health (SPF/DKIM/DMARC): a set-up status, not a scoreconfig.read
GET/api/public/v1/motor-blocks/{id}/error-codesSMTP error code diagnosticsanalytics.read
GET/api/public/v1/motor-blocks/{id}/events/streamEvent stream (SSE)logs.read
GET/api/public/v1/motor-blocks/{id}/exportsList recent export jobsanalytics.read
POST/api/public/v1/motor-blocks/{id}/exportsCreate export jobanalytics.read
GET/api/public/v1/motor-blocks/{id}/exports/previewPreview recent logs (no job creation)analytics.read, logs.read
GET/api/public/v1/motor-blocks/{id}/logsSearch logs with cursor paginationlogs.read
GET/api/public/v1/motor-blocks/{id}/metricsMetrics series and totalsanalytics.read
GET/api/public/v1/motor-blocks/{id}/overviewMotor Block overviewanalytics.read, usage.read
GET/api/public/v1/motor-blocks/{id}/providersProvider breakdown (gmail, outlook, yahoo, other)analytics.read
GET/api/public/v1/motor-blocks/{id}/rate-limitsMotor Block rate limitsusage.read
GET/api/public/v1/motor-blocks/{id}/reputationDelivery reputation scoreanalytics.read
GET/api/public/v1/motor-blocks/{id}/webhooksList webhookswebhooks.read
POST/api/public/v1/motor-blocks/{id}/webhooksCreate webhookwebhooks.manage
PUT/api/public/v1/motor-blocks/{id}/webhooks/{webhookId}Update webhookwebhooks.manage
DELETE/api/public/v1/motor-blocks/{id}/webhooks/{webhookId}Delete webhookwebhooks.manage
GET/api/public/v1/motor-blocks/{id}/webhooks/{webhookId}/deliveriesWebhook delivery historywebhooks.read
GET/api/public/v1/motor-blocks/{id}/webhooks/{webhookId}/statsWebhook delivery statswebhooks.read
POST/api/public/v1/motor-blocks/{id}/webhooks/{webhookId}/testEnqueue a test webhook deliverywebhooks.manage