Skip to content

Latest commit

 

History

History
2945 lines (2937 loc) · 172 KB

API Reference.md

File metadata and controls

2945 lines (2937 loc) · 172 KB

Here's a list of APIs we're working on, this API can be consumed through different interfaces regardless if its web or mobile app. Please notice that each API endpoint respects security context, so only authorized users may call a specific endpoint.

Endpoint

Path

Method

User Role

Params

Response

Notes

Programs Service

/programs

Get

Program Manager

List of all programs

/programs

Get

Public

{Country/City}

List of published programs for this area

/programs

Post

Program Manager

{program details}

success/fail response

/programs

Delete

Program Manager

{program id}

success/fail response

/programs/Publish

Post

Program Manager

{program id}

success/fail response

- Create program in DB
- Publish schema on sovrin
- Publich cred.def. on sovrin

/programs/Unpublish

Post

Program Manager

{program id}

success/fail response

/programs/GetProofRequest

Get

Public

{program id}

/programs/IncludeMe

Post

Public

{program id, proofs}

success/fail response

the success/fail response is for the REST request not for the inclusion, the inclusion response should be async.

/programs/InclusionStatus

Get

public

{program id, DID}

NA / Pending/ Missing Docs/ Included / Rejected

Authentication Service

/users

Get

Portal Admin

List of all users

/users

Post

Portal Admin

success/fail response

/users/ResetPassword

Post

Portal Admin

{user id, new_password}

success/fail response

/users/CreateRegistrationLink

Post

Portal Admin

{program id, valid until, role id}

success/fail response

/users/AssignUserToProgram

Post

Program Manager

{user id, program id}

success/fail response

/users/AssignUserToRole

Put

Portal Admin

{user id, role id}

success/fail response

/users/id

Delete

Portal Admin

{user id}

success/fail response

/users/ActivateUser

Post

Portal Admin

{user id}

success/fail response

/users/DeactivateUser

Post

Portal Admin

{user id}

success/fail response

Sovrin Service

/sovrin/CreateSchema

Post

Program Manager

{schema details}

success/fail response

/sovrin/IssueCredential

Put

Aid worker

credential type/ answers, DID

Credential file

/sovrin/RequestCredential

Get

Public

{credential type}

{Credential form fields}

/sovrin/RequestConnection

Post

Public

{}

/sovrin/SubmitClaims

Post

Public

{DID, credential type, answers}

success/fail response

Schedule Service

/schedule

Get

Program Manager

{program id, location}

List of all appointments without PII

/schedule/My

Get

Aid Worker

{user id}

Appointments for the logged in user

/schedule/FreeSpots

Get

Public

{location, program id}

List of free spots for all AWs serving this area

/schedule/BookSpot

Post

Public

{spot details}

success/fail response

/schedule/UpdateAvailability

Post

Aid Worker

{schedule}

success/fail response

Notification Service

/notifications/sms

System

/notifications/call

System

/notifications/push

System

/notifications/email

System

Voucher Service

/voucher/Count

Get

Public?

{user id}

Number of unredeemed vouchers

Funding Service

/funding/AvailableBalance

Get

System

amount and currency

/funding/TotalBalance

Get

System

amount and currency

FSP Service

Allocation Service

Aid Distribution Service

FSP Service

HealthCheck Service