> ## Documentation Index
> Fetch the complete documentation index at: https://docs.tesouro.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Submit application

> Submit a completed acceptor application for validation and underwriting review using the submitAcceptorApplication GraphQL mutation.

Once all required information is provided, call submitAcceptorApplication to validate and begin processing.

<Callout icon="clapperboard-play" color="#6938EF" type="scenario">
  **Scenario**

  A developer at Clearpath Payments has completed the Maple Street Coffee sub-merchant application with all business details, stakeholder information, and bank account details. They're now ready to submit the application for underwriting review.
</Callout>

<CodeGroup>
  ```graphql Operation lines theme={null}
  mutation SubmitAcceptorApplication($input: AcceptorApplicationSubmitInput!) {
    submitAcceptorApplication(input: $input) {
      acceptorApplication {
        applicationStatus
      }
      errors {
        ... on Error {
          message
          __typename
        }
      }
    }
  }
  ```

  ```json Variables lines theme={null}
  {
    "input": {
      "id": "60c66576-0caf-4dd1-8c66-fccae049f0fd"
    }
  }
  ```
</CodeGroup>

**Possible outcome: Validation passes**

If `submitAcceptorApplication` passes validation, underwriting begins automatically and you can expect the following field in the response:

* `applicationStatus` is `PROCESSING`

Next step:
Monitor the application status and review underwriting results once processing is complete

```json title="Response" lines theme={null}
{
  "data": {
    "submitAcceptorApplication": {
      "acceptorApplication": {
        "applicationStatus": "PROCESSING"
      },
      "errors": []
    }
  }
}
```

**Possible outcome: Validation fails**<br />

If submitAcceptorApplication fails validation, the response will include an `errors` field describing the issues, and status field will be:

* `applicationStatus` is `SUBMISSION_INVALID`

Next step:
Gather necessary missing details and update application, then resubmit via submitAcceptorApplication.

```json title="Response" lines expandable theme={null}
{
  "data": {
    "submitAcceptorApplication": {
      "acceptorApplication": {
        "applicationStatus": "SUBMISSION_INVALID"
      },
      "errors": [
        {
          "code": "INVALID_MERCHANT_CATEGORY_CODE",
          "message": "Invalid MerchantCategoryCode"
        },
        {
          "code": "INVALID_TELEPHONE_NUMBER",
          "message": "Service telephone number must be valid"
        },
        {
          "code": "INVALID_COUNTRY_CODE",
          "message": "Country code must be USA"
        },
        {
          "code": "INVALID_BUSINESS_ENTITY_TYPE",
          "message": "Business entity type must be set"
        },
        {
          "code": "INVALID_TAX_IDENTIFICATION_NUMBER",
          "message": "Tax identification number must be set to a valid SSN or TIN"
        },
        {
          "code": "INVALID_EMAIL_ADDRESS",
          "message": "Stakeholder email address must be valid"
        },
        {
          "code": "INVALID_TELEPHONE_NUMBER",
          "message": "Stakeholder telephone number must be valid"
        },
        {
          "code": "INVALID_EMAIL_ADDRESS",
          "message": "Stakeholder email address must be valid"
        },
        {
          "code": "INVALID_TELEPHONE_NUMBER",
          "message": "Stakeholder telephone number must be valid"
        },
        {
          "code": "INVALID_CHARGEBACK_PERCENTAGE",
          "message": "Chargeback Percentage must be greater than 0 and less than or equal to 100"
        },
        {
          "code": "INVALID_REFUND_RATE_PERCENTAGE",
          "message": "Refund Rate Percentage must be greater than 0 and less than or equal to 100"
        }
      ]
    }
  }
}
```

**Possible outcome: System failure**<br />

If the submitAcceptorApplication mutation fails due to a system error, the response will include an errors field detailing the issue. The status field will be set as follows:

* applicationStatus: `SUBMISSION_FAILED`

Next steps:
Retry the request. If the error persists, contact Tesouro support for technical assistance.

```json title="Response" lines expandable theme={null}
{
  "data": {
    "submitAcceptorApplication": {
      "acceptorApplication": {
        "applicationStatus": "SUBMISSION_FAILED"
      },
      "errors": [
        {
          "code": "INTERNAL_SERVICE_ERROR",
          "message": "An unexpected error occurred while processing your request."
        }
      ]
    }
  }
}
```

### What to expect after submitting an application

Once you've submitted a valid application using submitAcceptorApplication, our system will automatically trigger the underwriting process. The underwriting results determine whether the application is:

* `Approved`, No further action required
* `Action Required`, Follow-up requirements will be shown in the underwriting results.

Although APIs are available to retrieve and review underwriting outcomes, most integrators will rely on the user interface provided by Tesouro.
