Account Rejected

Notifying when business creation fails

When an async business creation fails (asynchronous mode set using synchronized: false),
a webhook is sent to subscribers of the account entity with event_type: 'rejected'.

Basic Structure

{
  "email": "[email protected]",
  "external_reference_id": "unique_id_12345",
  "errors": [
    {
      "field_name": [
        "error message 1",
        "error message 2"
      ]
    }
  ]
}

Example 1: Business Name Validation Error

{
  "email": "[email protected]",
  "external_reference_id": "partner_business_001",
  "errors": [
    {
      "business_name": [
        "contains invalid term"
      ]
    }
  ]
}

Example 2: Multiple Validation Errors

{
  "email": "[email protected]",
  "external_reference_id": "unique_id_12345",
  "errors": [
    {
      "business_name": [
        "contains invalid term"
      ]
    },
    {
      "email": [
        "email already exists",
        "invalid email format"
      ]
    },
    {
      "password": [
        "password is too weak",
        "password must contain at least 8 characters"
      ]
    }
  ]
}

Example 3: Missing Required Fields

{
  "email": "[email protected]",
  "external_reference_id": "unique_id_12345",
  "errors": [
    {
      "business_name": [
        "is required"
      ]
    },
    {
      "email": [
        "is required"
      ]
    }
  ]
}

Example 4: Business Category Validation Error

{
  "email": "[email protected]",
  "external_reference_id": "unique_id_12345",
  "errors": [
    {
      "business_category": [
        "invalid business category",
        "must be a valid category from the allowed list"
      ]
    }
  ]
}

Example 5: External Reference ID Conflict

{
  "email": "[email protected]",
  "external_reference_id": "existing_id_123",
  "errors": [
    {
      "external_reference_id": [
        "already exists",
        "must be unique"
      ]
    }
  ]
}

Example 6: Without External Reference ID

If external_reference_id was not provided in the original request, it will be omitted from the webhook payload:

{
  "email": "[email protected]",
  "errors": [
    {
      "business_name": [
        "contains invalid term"
      ]
    }
  ]
}

Example 7: Complex Validation Errors

{
  "email": "[email protected]",
  "external_reference_id": "partner_business_002",
  "errors": [
    {
      "business_name": [
        "contains invalid term",
        "must be between 1 and 100 characters"
      ]
    },
    {
      "website_url": [
        "invalid URL format",
        "must include http:// or https://"
      ]
    },
    {
      "phone": [
        "invalid phone number format"
      ]
    },
    {
      "admin_account": [
        "email already registered",
        "password does not meet security requirements"
      ]
    }
  ]
}

Webhook Subscription

To receive these webhooks, subscribe using:

{
  "entity": "account",
  "event_type": "rejected",
  "url": "https://your-domain.com/webhooks/account-rejected"
}

Notes

  • The email field is always present and corresponds to the email provided in the admin_account.email field
  • The external_reference_id field is only present if it was provided in the original request
  • The errors array contains one or more error objects, where each object key is the field name and the value is an array of error messages for that field
  • Multiple fields can have errors, and each field can have multiple error messages
  • Error messages are descriptive and help identify what went wrong during business creation