Third-party apps

Developer sign-up

How a developer’s agent creates the account and asks for its first project, with no browser: a code mailed to the person, then the project and its screenshots. Masjidbox staff review the project by hand before any key exists.

No key: these calls are how a developer gets one.

Email me a sign-up code

POST/api/public/developer/sign-up

The first step of a sign-up an agent can drive, with no browser and no cookie: mails a six-digit code to the address, valid 15 minutes, with a link to the developer terms. Ask the person for the code, then send it to POST /developer/sign-up/verify with the project. The answer is the same whether the address has an account or not; an address asking for more than five codes an hour, or a network for more than twenty, gets none.

Parameters

No parameters.

Request body

  • emailstringrequired

    The work email of the person signing up.

  • languageen | fr

    The mail's language when the address has no account yet; else the account's. English when absent.

Returns

If the address can receive email, a code is on its way.

  • senttrue

    Always true.

POST /api/public/developer/sign-up
curl -X POST "https://hub.masjidbox.com/api/public/developer/sign-up" \
  -H "Content-Type: application/json" \
  -d '{"email":"dev@example.com","language":"fr"}'
Example request · HubSignUpCodeBody
{
  "email": "dev@example.com",
  "language": "fr"
}
202 · HubSignUpCodeAccepted
{
  "sent": true
}

Create my account and project with a code

POST/api/public/developer/sign-up/verify

Spends the sign-up code and, with no session, creates the developer account of the address (or takes the one it holds), records the acceptance of the developer terms and sends the project to Masjidbox staff for review. The project is pending and holds no key until staff approve it, by hand; the person is emailed the decision and creates keys in the portal. Upload each screenshot to its presigned URL: then confirm each one with the answered uploadToken (POST /developer/sign-up/screenshots/{screenshotId}/confirm): the review reaches staff once every screenshot is confirmed. A code that is wrong, expired, already used or tried five times is a 401, the same for the four; an invalid body is a 400 and leaves the code unspent. 409 when the account is suspended or revoked.

Parameters

No parameters.

Request body

  • emailstringrequired

    The address the code was mailed to.

  • codestringrequired

    The six-digit code from the mail.

  • acceptTermstruerequired

    The person accepts the developer terms linked in the mail, on behalf of the account. Ask them before sending true.

  • accountobjectrequired

    The developer account to create.

    Show child attributes (1)
    • namestringrequired

      The account name, shown to Masjidbox staff. Ignored when the address already has an account.

  • languageen | fr

    A new account's email language (English when absent).

  • projectobjectrequired

    The project sent to staff for review: an https link and 1 to 3 screenshots are required.

    Show child attributes (8)
    • platformsstring[]required

      Every platform the project ships on.

    • intendedUsestringrequired

      What the project does with Masjidbox data, 30 to 2000 characters.

    • linkstringrequired

      The app’s store page, the site, or a demo: an https link.

    • audiencestringrequired

      The audience, estimated.

    • screenshotsobject[]required

      1 to 3 screenshots of where Masjidbox data appears, 10 MB each.

    • screenshots[].contentTypeimage/jpeg | image/pngrequired

      JPEG or PNG; checked against the file’s first bytes once uploaded.

    • screenshots[].sizeBytesintegerrequired

      The exact size of the file, in bytes: the upload link binds it.

    • namestringrequired

      Display name, 1 to 100 characters.

Returns

The account, the project pending, its review, and where to upload each screenshot.

    POST /api/public/developer/sign-up/verify
    curl -X POST "https://hub.masjidbox.com/api/public/developer/sign-up/verify" \
      -H "Content-Type: application/json" \
      -d '{"email":"dev@example.com","code":"042917","acceptTerms":true,"account":{"name":"Prayer Widget Co"},"language":"fr","project":{"audience":"10,000 – 100,000 monthly users","intendedUse":"Shows the nearest mosques and today’s prayer times, cached on the device.","link":"https://apps.example.com/mosque-finder","name":"Mosque finder (iOS)","platforms":["ios"],"screenshots":[{"contentType":"image/png","sizeBytes":412000}]}}'
    Example request · HubSignUpBody
    {
      "email": "dev@example.com",
      "code": "042917",
      "acceptTerms": true,
      "account": {
        "name": "Prayer Widget Co"
      },
      "language": "fr",
      "project": {
        "audience": "10,000 – 100,000 monthly users",
        "intendedUse": "Shows the nearest mosques and today’s prayer times, cached on the device.",
        "link": "https://apps.example.com/mosque-finder",
        "name": "Mosque finder (iOS)",
        "platforms": [
          "ios"
        ],
        "screenshots": [
          {
            "contentType": "image/png",
            "sizeBytes": 412000
          }
        ]
      }
    }
    201 · HubSignedUp
    {
      "project": {
        "accountId": "3f2a1c4e-5b6d-4e7f-8a9b-0c1d2e3f4a5b",
        "createdAt": "2026-10-19T14:12:00.000Z",
        "id": "9c2d5e81-4b6a-4d7c-a8e9-3f1b2c4d5e6f",
        "name": "Mosque finder (iOS)",
        "quota": {
          "masjidsPerDay": 2000,
          "requestsPerMinute": null
        },
        "reviewStatus": "pending"
      },
      "review": {
        "audience": "10,000 – 100,000 monthly users",
        "decidedAt": null,
        "id": "7b1e4c90-2a3d-4f5e-8c6b-1d2e3f4a5b6c",
        "intendedUse": "Shows the nearest mosques and today’s prayer times, cached on the device.",
        "link": "https://apps.example.com/mosque-finder",
        "object": "project_review",
        "platforms": [
          "ios"
        ],
        "projectId": "9c2d5e81-4b6a-4d7c-a8e9-3f1b2c4d5e6f",
        "reason": null,
        "screenshots": [
          {
            "contentType": "image/png",
            "id": "6f1c2d3e-4b5a-4c6d-8e7f-9a0b1c2d3e4f",
            "object": "project_screenshot",
            "sizeBytes": 412000,
            "status": "pending"
          }
        ],
        "status": "uploading",
        "submittedAt": "2026-10-19T14:12:00.000Z"
      },
      "uploads": [
        {
          "expiresAt": "2026-10-19T14:27:00.000Z",
          "headers": {
            "content-length": "412000",
            "content-type": "image/png"
          },
          "method": "PUT",
          "screenshotId": "6f1c2d3e-4b5a-4c6d-8e7f-9a0b1c2d3e4f",
          "url": "https://r2.example.com/project-reviews/uploads/acc/token?X-Amz-Signature=abc123"
        }
      ],
      "uploadToken": "example-upload-token-from-the-sign-up",
      "account": {
        "id": "3f2a1c4e-5b6d-4e7f-8a9b-0c1d2e3f4a5b",
        "name": "Prayer Widget Co"
      }
    }

    Confirm a screenshot uploaded after an agent sign-up

    POST/api/public/developer/sign-up/screenshots/{screenshotId}/confirm

    For an agent, with no session: once a screenshot is uploaded to its presigned URL, confirms it with the uploadToken the sign-up answered (valid a day, for that review only). The checks are the portal’s: exact size, real type from the first bytes. With the last screenshot confirmed the review turns pending and reaches staff. 401 for a token that is unknown or expired; 404 for a screenshot of another review; 409 while nothing is uploaded; 422 when the upload is not the file declared (it is deleted: send the project again from the portal).

    Parameters

    • screenshotIdstring · pathrequired

      The screenshot, as the request answered it.

    Request body

    • tokenstringrequired

      The uploadToken POST /developer/sign-up/verify answered.

    Returns

    The screenshot, checked and kept, and its review.

    • screenshotobject

      A screenshot of the project, as the developer declared it.

      Show child attributes (5)
      • idstring

        The screenshot.

      • objectproject_screenshot

        Always project_screenshot.

      • contentTypeimage/jpeg | image/png

        JPEG or PNG; checked against the file’s first bytes once uploaded.

      • sizeBytesinteger

        Its size, in bytes.

      • statuspending | confirmed

        pending until uploaded and confirmed.

    • reviewobject

      One submission of a project to Masjidbox staff, and their decision.

      Show child attributes (17)
      • idstring

        The review: one submission of the project.

      • objectproject_review

        Always project_review.

      • projectIdstring

        The project it is for.

      • platformsstring[]

        Every platform the project ships on.

      • intendedUsestring

        What the project does with the data.

      • linkstring

        The app’s store page, the site, or a demo.

      • audiencestring

        The audience, as the developer estimated it.

      • statusuploading | pending | info_requested | approved | refused

        uploading until each screenshot is confirmed, pending while staff review it, info_requested while staff wait on the developer’s reply to a question, then the decision.

      • reasonstring | null

        Staff’s reason, on a refusal, as written.

      • submittedAtstring

        When the project was sent.

      • decidedAtstring | null

        When staff decided; null until then.

      • screenshotsobject[]

        Its screenshots, in the order they were declared.

      • screenshots[].idstring

        The screenshot.

      • screenshots[].objectproject_screenshot

        Always project_screenshot.

      • screenshots[].contentTypeimage/jpeg | image/png

        JPEG or PNG; checked against the file’s first bytes once uploaded.

      • screenshots[].sizeBytesinteger

        Its size, in bytes.

      • screenshots[].statuspending | confirmed

        pending until uploaded and confirmed.

    POST /api/public/developer/sign-up/screenshots/{screenshotId}/confirm
    curl -X POST "https://hub.masjidbox.com/api/public/developer/sign-up/screenshots/3f0c2a52-7d8e-4b1a-9c6f-2e5d8a4b7c10/confirm" \
      -H "Content-Type: application/json" \
      -d '{"token":"example-upload-token-from-the-sign-up"}'
    Example request · HubConfirmSignUpScreenshotBody
    {
      "token": "example-upload-token-from-the-sign-up"
    }
    200 · HubConfirmedProjectScreenshot
    {
      "screenshot": {
        "contentType": "image/png",
        "id": "6f1c2d3e-4b5a-4c6d-8e7f-9a0b1c2d3e4f",
        "object": "project_screenshot",
        "sizeBytes": 412000,
        "status": "confirmed"
      },
      "review": {
        "audience": "10,000 – 100,000 monthly users",
        "decidedAt": null,
        "id": "7b1e4c90-2a3d-4f5e-8c6b-1d2e3f4a5b6c",
        "intendedUse": "Shows the nearest mosques and today’s prayer times, cached on the device.",
        "link": "https://apps.example.com/mosque-finder",
        "object": "project_review",
        "platforms": [
          "ios",
          "android"
        ],
        "projectId": "9c2d5e81-4b6a-4d7c-a8e9-3f1b2c4d5e6f",
        "reason": null,
        "screenshots": [
          {
            "contentType": "image/png",
            "id": "6f1c2d3e-4b5a-4c6d-8e7f-9a0b1c2d3e4f",
            "object": "project_screenshot",
            "sizeBytes": 412000,
            "status": "confirmed"
          }
        ],
        "status": "pending",
        "submittedAt": "2026-10-19T14:12:00.000Z"
      }
    }