Versions Compared

Key

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

...

To ensure data privacy and security, transactional APIs in DIGIT are protected under authentication. System integrators are requested to contact respective state authority to get the necessary OAUTH tokens that can be used to access these APIs. Kindly note that apart from userid/password system may enforce IP based access control in which case integrator may be required to share IP or range of IPs from which the request will originate.
To generate the access token based on the credentials provided, please use the following API -
Given below is the example of the request and response, OAuth token to be used from the response is highlighted in Bold.

Request Snippet:

curl -X POST \

...


    https://egov-micro-dev.egovernments.org/user/oauth/

...

token \
    -H 'Authorization: Basic 

...

{Authorization Token}'

...

 \
    -H 'Content-Type: application/x-www-form-urlencoded'

...

 \
    -H 'Postman-Token: 81c87b4c-f69d-464a-8c9a-990e698391ec'

...

 \
    -H 'cache-control: no-cache'

...

 \
    -d 'grant_type=password&scope=read&username=

...

{username}&password={Password}&tenantId={TenantId}&userType=Employee'


Response Snippet:

{

...


"access_token": "6cf92021-8433-4da3-9a1e-8bc511983b2f",

...


"token_type": "bearer",

...


"refresh_token": "1f3097f3-39ab-4fd1-91a9-2ce48ac5b6bc",

...


"expires_in": 604799,

...


"scope": "read"

...


}


2.Fetching Bill:

DIGIT allows the integrators to fetch the bills for citizens using the Consumer number of the respective service (e.g. Water charges, Property Service, Trade License). Please note that different services may have different notions of consumer number, e.g. for Water Charges consumer number will signify the "Connection number" while for Property it will be "Property Id".
For some services, DIGIT also provides the facility to fetch bill by mobile number, please note that a bill search by mobile number may return multiple bills across services and may not return bills from services that do not support mobile-number based search.
To support partial payment use case each bill in the response of the fetch bill API will indicate whether it is allowed to be partially paid and any minimum amount if partial payment is allowed.
To fetch a bill from DIGIT, please ensure that OAuth token is generated as per the Authentication section above. Post that you can use the following API to fetch the bill -

...