- Fetch the list of supported banks.
- Select a bank for a given session ID.
- Fetch the payment status for a given session ID.
- Create a payment URL for a given session ID.
- Update a payment URL for a given session ID.
- Fetch the payment URL consumed status for a given session ID.
- Fetch self assessment payments made within the last 14 days for the given UTR.
- Get a Web URL to complete the payment journey online with a pre-populated amount
- Create a session.
- Fetch a session for a given session ID.
- Set the email for a session given a session ID.
- Clear the email for a session given a session ID.
Please note it is mandatory to supply an Accept HTTP header to all below services with the
value application/vnd.hmrc.1.0+json.
- Run locally:
sbt runwhich runs on port8262by default - Run with test endpoints:
sbt 'run -Dplay.http.router=testOnlyDoNotUseInAppConf.Routes'
The service can be run locally from Service Manager, using the following profiles:
| Profile Details | Command |
|---|---|
| MOBILE_PAYMENTS_ALL | sm2 --start MOBILE_PAYMENTS_ALL |
- Run Unit Tests:
sbt test - Run Integration Tests:
sbt it:test - Run Unit and Integration Tests:
sbt test it:test - Run Unit and Integration Tests with coverage report:
sbt clean compile coverage test it:test coverageReport dependencyUpdates
| Task | Supported Methods | Description |
|---|---|---|
/banks |
GET | Fetch the list of supported banks. More... |
/banks/:sessionDataId |
POST | Select a bank for a given session ID. More... |
/payments/pay-by-card |
POST | Get a Web URL to complete the payment journey online with a pre-populated amount More... |
/payments/:sessionDataId |
GET | Fetch the payment status for a given session ID. More... |
/payments/:sessionDataId |
POST | Create a payment URL for a given session ID. More... |
/payments/:sessionDataId |
PUT | Update a payment URL for a given session ID. More... |
/payments/:sessionDataId/url-consumed |
GET | Fetch the payment URL consumed status for a given session ID. More... |
/payments/latest-payments |
POST | Fetch payments made within the last 14 days for the given tax type and reference. More... |
/payments/pay-by-card/:utr |
POST | Get a Web URL to complete the payment journey online with a pre-populated amount. More... |
/sessions |
POST | Create a session. More... |
/sessions/:sessionDataId |
GET | Fetch a session for a given session ID. More... |
/sessions/:sessionDataId/set-email |
POST | Set the email for a session given a session ID. More... |
/sessions/:sessionDataId/set-future-date |
POST | Set the futureDate for a session given a session ID. More... |
/sessions/:sessionDataId/clear-future-date |
DELETE | Clear the futureDate for a session given a session ID. More... |
/sessions/:sessionDataId/clear-email |
DELETE | Clear the email for a session given a session ID. More... |
Shuttering of this service is handled by mobile-shuttering
Most of the above endpoints are accessible on sandbox with /sandbox prefix on each endpoint, e.g.:
GET /sandbox/banksTo trigger the sandbox endpoints locally, use the "X-MOBILE-USER-ID" header with one of the following values: 208606423740 or 167927702220
To test different scenarios, add a header "SANDBOX-CONTROL" to specify the appropriate status code and return payload. See each linked file for details:
| Task | Supported Methods | Description |
|---|---|---|
sandbox/banks |
GET | Acts as a stub for the related live endpoint. More... |
sandbox/banks/:sessionDataId |
POST | Acts as a stub for the related live endpoint. More... |
sandbox/payments/pay-by-card |
POST | Acts as a stub for the related live endpoint. More... |
sandbox/payments/:sessionDataId |
GET | Acts as a stub for the related live endpoint. More... |
sandbox/payments/:sessionDataId |
POST | Acts as a stub for the related live endpoint. More... |
sandbox/payments/:sessionDataId |
PUT | Acts as a stub for the related live endpoint. More... |
sandbox/payments/:sessionDataId/url-consumed |
GET | Acts as a stub for the related live endpoint. More... |
sandbox/payments/latest-payments |
POST | Acts as a stub for the related live endpoint. More... |
sandbox/payments/pay-by-card/:utr |
POST | No sandbox endpoint |
sandbox/sessions |
POST | Acts as a stub for the related live endpoint. More... |
sandbox/sessions/:sessionDataId |
GET | Acts as a stub for the related live endpoint. More... |
sandbox/sessions/:sessionDataId/set-email |
POST | Acts as a stub for the related live endpoint. More... |
sandbox/sessions/:sessionDataId/set-future-date |
POST | Acts as a stub for the related live endpoint. More... |
sandbox/sessions/:sessionDataId/clear-future-date |
DELETE | Acts as a stub for the related live endpoint. More... |
sandbox/sessions/:sessionDataId/clear-email |
DELETE | Acts as a stub for the related live endpoint. More... |
API definition for the service will be available under /api/definition endpoint. See definition
in /conf/api-definition.json for the format.
This code is open source software licensed under the Apache 2.0 License