Skip to main content
Learn about the /reports endpoint.
Report objects contains information related to reports generated for a user, including:
Reports are generated on request and are based on data available from payroll providers. High level structure of the reports object.

The report object

Attributes

  • id (string (uuid), optional): Unique ID of the report object.
  • user (string (uuid), optional): A unique ID assigned to a user.
  • (Deprecated) reference_id (string, optional): Unique ID of the report referenced on the PDF.
  • generated_at (string (timestamp), optional): Shows the date and time when the report was generated.
  • type (note, optional)

{
"id": "9f82994c-774d-11eb-b1c7-13e87316bacb",
"user": "8a5f613a-673a-4434-aeee-1a38b960b936",
"reference_id": "9f82994c-774d-11eb-b1c7-13e87316bacb",
"generated_at": "2020-11-29T08:33:41.525Z",
"type": "voie",
"status": "generated",
"file_url": "www.company.com/voie_report.pdf",
"metadata": {
"purpose": "Risk Assesment"
}
},
null,
2
  

Generate a report

POST /v1/reports
  • Generate a report of the desired type for the specified user.
  • This request returns a report object if a valid user was provided.

Request body

  • user (string (uuid), required): Unique user ID.
  • metadata (object, required)
curl --request POST \\
--url https://api.argyle.com/v1/reports \\
--header 'accept: application/json' \\
--header 'content-type: application/json' \\
--data '{
"user": "8a5f613a-673a-4434-aeee-1a38b960b936",
"type": "voie",
"metadata": {
  "purpose": "Risk Assessment"
}
}'

{
  "id": "b1347b20-c667-4250-9a99-2e1f17d28f11",
  "user": "8a5f613a-673a-4434-aeee-1a38b960b936",
  "reference_id": "b1347b20-c667-4250-9a99-2e1f17d28f11",
  "type": "voie",
  "status": "waiting_for_sync",
  "metadata": {
"purpose": "Risk Assessment"
  },
  "file_url": null,
  "created_at": "2022-04-22T16:25:05.289Z",
  "updated_at": "2022-04-22T16:25:05.289Z",
  "generated_at": null
},
null,
2
  

Retrieve a report

GET /v1/reports/{id}
  • Retrieve a report object for a supplied ID.
  • This request returns a report object if a valid ID was provided.

Path parameters

  • id (string (uuid), required): The identifier of the report to be retrieved.
curl --request GET \\
--url https://api.argyle.com/v1/reports/{id} \\
--header 'accept: application/json' \\
--header 'content-type: application/json'
  

{
  "id": "b1347b20-c667-4250-9a99-2e1f17d28f11",
  "reference_id": "b1347b20-c667-4250-9a99-2e1f17d28f11",
  "generated_at": null,
  "type": "voie",
  "user": "8a5f613a-673a-4434-aeee-1a38b960b936",
  "status": "waiting_for_sync",
  "file_url": null,
  "metadata": {
"purpose": "Risk Assessment"
  }
},
null,
2
  

List reports

GET /v1/reports
  • List all reports.
  • This request returns a list of all reports generated.

Query parameters

curl --request GET \\
--url https://api.argyle.com/v1/reports?limit=2 \\
--header 'accept: application/json' \\
--header 'content-type: application/json'
  

[
  {
"id": "8ecbc2d2-d2cb-4134-8dcd-739cf36baa75",
"reference_id": "8ecbc2d2-d2cb-4134-8dcd-739cf36baa75",
"generated_at": null,
"type": "voie",
"user": "8a5f613a-673a-4434-aeee-1a38b960b936",
"status": "waiting_for_sync",
"file_url": null,
"metadata": {
  "purpose": ""
}
  },
  {
"id": "b1347b20-c667-4250-9a99-2e1f17d28f11",
"reference_id": "b1347b20-c667-4250-9a99-2e1f17d28f11",
"generated_at": null,
"type": "voie",
"user": "8a5f613a-673a-4434-aeee-1a38b960b936",
"status": "waiting_for_sync",
"file_url": null,
"metadata": {
  "purpose": "Risk Assessment"
}
  }
],
null,
2