Browse documentation

Movik-hosted endpoints

Two endpoints are served by movik.us directly rather than by the API host. They do not share the API's authentication model, so read this page before calling them.

Two different credentials

The serverless API at api.dev.movik.us authenticates with a Cognito bearer token. The endpoints on this page do not both work that way, and sending the wrong credential is the most likely mistake:

  • POST /api/integrations/token — takes your service email and password, returns a Cognito token. Covered in Authentication.
  • GET /api/public/broker-referral — takes a static API key in an x-api-key header. A Cognito bearer token will not authenticate it, and the API key will not authenticate anything else.

Broker referral lookup

Returns a broker’s referral code and referral statistics, looked up by their email address. Built for marketing campaigns that need to show a broker their own referral link.

GEThttps://movik.us/api/public/broker-referral

Headers

x-api-key — required. Issued to you separately from your service credentials.

Query parameters

email— required. The broker’s registered email address. Matched case-insensitively.

Example request

bash
curl 'https://movik.us/api/public/broker-referral?email=broker@example.com' \
  -H "x-api-key: $MARKETING_API_KEY"

Response

json
{
  "success": true,
  "data": {
    "brokerEmail": "broker@example.com",
    "brokerName": "Jane Doe",
    "organizationName": "Example Logistics LLC",
    "referralCode": "MV-A3X9K2",
    "referralUrl": "https://movik.us/signup?ref=MV-A3X9K2",
    "joinedDate": "2026-03-14T09:21:00.000Z",
    "totalReferrals": 12
  }
}
FieldDescription
brokerEmailThe broker's registered email address.
brokerNameThe broker's first and last name.
organizationNameLegal business name of the broker organization.
referralCodeThe referral code itself, e.g. MV-A3X9K2.
referralUrlComplete signup URL with the referral code applied.
joinedDateWhen the broker organization was created.
totalReferralsNumber of carriers referred by this broker.

Errors

401Missing or wrong x-api-key.
400The email query parameter was omitted.
403The account exists but is not a broker organization.
404No user with that email, no active organization, or no referral code generated yet — the broker has to finish their application before a code exists.
500MARKETING_API_KEY is not configured on the server, or an unexpected fault.

A 404 covers several distinct situations — unknown email, no active organization, and no referral code yet — so read the error string in the body to tell them apart. Only the last of those is likely to resolve on its own, once the broker completes their application.