Skip to content

Instantly share code, notes, and snippets.

@hendri1
Last active April 22, 2020 12:46
Show Gist options
  • Save hendri1/8aff5abf337ab3756d8af78ead172a90 to your computer and use it in GitHub Desktop.
Save hendri1/8aff5abf337ab3756d8af78ead172a90 to your computer and use it in GitHub Desktop.
Job List Contract API

Job List API Contract

Requirement

Data:
1. Job Name
2. Status
3. Date Created
4. Job Type
5. Who Created
6. Progress
7. Estimate
Filter:
1. Can be filtered progress (on going, complete, all)
2. Can be filtered by date
3. Can be filtered by job name

API

Client: ${BASE_URL}/api/v1/job/all

Admin: ${BASE_URL}/api/v1/admin/job/all

Method: GET

Query Parameter

1. per_page
2. current_page
3. type
4. name
5. created_at

Example Response

{
  "data": [
    {
      "name": "Job Name",
      "status": "ongoing",
      "created_at": "2020-04-17T11:57:30.617Z",
      "type": "text"
      "type_name": "tagging",
      "client": "Username Client",
      "progress": 10,
      "estimate": 1
    }
  ],
  "paginate": {
    "current_page": 1,
    "per_page": 5,
    "total_page": 25,
    "total_data": 124
  }
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment