Skip to content

Ledger/Sales service (1.0)

Using Swagger documentation in Postman


You can find instructions on how to convert swagger documentation to Postman collection here.
There is a known problem in Postman with env variables being imported as parameters (:schemaName instead of {{schemaName}}. More info on the issue can be found here.
Possible workaround is to find and replace all parameters with env variables inside Postman. For example search for :schemaName and replace with {{schemaName}}. Instructions how to do it in Postman are here.

Authorization

To obtain a token, start by visiting the identifier service documentation and make a request with your username and password.
Once you receive the response, copy the access_token and use it for making requests to ledger services.
Download OpenAPI description
Languages
Servers
Mock server

https://ledger.docs.insly.com/_mock/apis/ledger/bundled/

Beta

https://ledger.app.beta.insly.training/

Demo

https://ledger.app.demo.insly.com/

Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations

Preparing data before renewal quote create

Request

Preparing data before renewal quote create

Security
bearerAuth
Path
policyIdintegerrequired
Example: 1
Headers
X-TENANT-IDstringrequired

Tenant tag

Example: {$inputs.tenant}
curl -i -X GET \
  https://ledger.docs.insly.com/_mock/apis/ledger/bundled/api/v1/ledger/policies/1/renewal \
  -H 'Authorization: Bearer <YOUR_JWT_HERE>' \
  -H 'X-TENANT-ID: {$inputs.tenant}'

Responses

Full request structure per product can be taken from json scheme Product json scheme. with type: policy and name: {name of the insurance product}.

Bodyapplication/json
any
Response
application/json
[]

Request

Security
bearerAuth
Path
policyIdintegerrequired

Policy id

Example: 123
Headers
X-TENANT-IDstringrequired

Tenant tag

Example: {$inputs.tenant}
curl -i -X GET \
  https://ledger.docs.insly.com/_mock/apis/ledger/bundled/api/v1/ledger/policies/123/invoices \
  -H 'Authorization: Bearer <YOUR_JWT_HERE>' \
  -H 'X-TENANT-ID: {$inputs.tenant}'

Responses

Return policy invoices data

Bodyapplication/json
Array of objects
[].​invoicenumberstring
Example: "100011517"
[].​duedatestring(date)
Example: "2022-02-01"
[].​premiumnumber
Example: "65.89"
[].​adminfeenumber
Example: "55.23"
[].​mgacommnumber
Example: "18.00"
[].​brokercommnumber
Example: "1.01"
[].​payablenull
Example: "null"
Response
application/json
{ "": [ { … } ] }

Request

Security
bearerAuth
Path
policyIdintegerrequired

Policy id

Example: 123
versioninteger

Version of policy. Version 1 = original policy installments, version 2 - first MTA installments.

  • By default, return the latest installments totals.
Example: 1
Headers
X-TENANT-IDstringrequired

Tenant tag

Example: {$inputs.tenant}
curl -i -X GET \
  'https://ledger.docs.insly.com/_mock/apis/ledger/bundled/api/v1/ledger/policies/{id}/period-totals' \
  -H 'Authorization: Bearer <YOUR_JWT_HERE>' \
  -H 'X-TENANT-ID: {$inputs.tenant}'

Responses

Successful response with policy total financials.

Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations