Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Code Block
languagejson
curl -X POST "https://test.onboarding.namirial.app/api/v2/requests?idempotencyKey=YOUR_IDEMPOTENCY_KEY" \
-H "Content-Type: application/json" \
-H "Accept: application/json" \
-H "X-Api-Key: YOUR_API_KEY" \
-d '{
  "requestTypeId": "123e4567-e89b-12d3-a456-426614174000",
  "referenceId": "YOUR_REFERENCE_ID",
  "parameters": {
    "customerNamefirstName": "John Doe"Mario",
    "lastName": "Rossi",
    "customerEmailpersonalNumber": "john.doe@example.comRSSMR000000"
  },
  "settings": {
    "wizardUrlBack": "https://webhook.site/2c47164f-fc65-44cd-a8c4-a2c806fb6c8a?requestId=<requestId>&referenceId=<referenceId>&status=<status>&requestTypeId=<requestTypeId>&actor=<actor>"
  }
}'

...

  • 200 OK

    • Description: The created request.

    • Example Response:

      Code Block
      languagejson
      {
        "id": "123e4567-e89b-12d3-a456-426614174001",
        "organizationId": "123e4567-e89b-12d3-a456-426614174002",
        "status": "CREATED",
        "referenceId": "order-1234-0002",
        "requestTypeId": "123e4567-e89b-12d3-a456-426614174000",
        "parameters": {
          "customerNamefirstName": "John Doe"Mario",
          "lastName": "Rossi",
          "customerEmailpersonalNumber": "john.doe@example.comRSSMR000000"
        },
        "createdAt": "2024-10-29T17:42:16.269594Z",
        "updatedAt": "2024-10-29T17:42:16.269594Z",
        "finalizedAt": null,
        "expireAfter": "2024-11-29T17:42:16.269594Z",
        "links": [
          {
            "actor": "customer",
            "link": "https://onboarding.example/res/3949?ts=49943",
            "expiresAfter": "2024-11-29T17:42:16.269594Z"
          }
        ]
      }
  • 400 Bad Request

    • Description: Bad Request described following Problem Details (RFC 9457).

    • Example Response:

      Code Block
      languagejson
      {
        "type": "about:blank",
        "status": 400,
        "title": "Request validation error",
        "detail": "The has a malformed body property.",
        "instance": "urn:uuid:123e4567-e89b-12d3-a456-426614174000?ts=1729667463",
        "retryable": false,
        "errors": [
          {
            "detail": "Property 'dummyField' is not defined in the schema and the schema does not allow additional properties.",
            "pointer": "/parameters/dummyField",
            "field": "dummyField",
            "reason": "additionalProperties"
          }
        ]
      }

...