Courses
APIs related to courses
List Courses
GET https://example.com/api/courses
This endpoint will return a list of courses if a valid accessToken is provided as a Bearer token You can use the login API to generate fresh accessToken
Headers
Name
Type
Description
Authorization
string
Bearer 7|vC2gUQC8ajaMOa2juAnaiE4ZLgmH5dcbCDY8Hwsy
Accept
string
application/json
{
"data": [
{
"id": 1,
"name": "Block Based Coding",
"sub_category": "Class 3 to 5 ",
"category": "Coding for kids",
"image": "https://zero-to-one.s3.ap-south-1.amazonaws.com/course-images/2021-04-20 08:27:01_course_1",
"type": "Live",
"cost_price": 19999,
"selling_price": 9999
},
{
"id": 2,
"name": "HTML & Graphics Designing",
"sub_category": "Class 6 to 8 ",
"category": "Coding for kids",
"image": "https://zero-to-one.s3.ap-south-1.amazonaws.com/course-images/2021-04-20 08:57:47_course_2",
"type": "Live",
"cost_price": 19999,
"selling_price": 9999
}
],
"links": {
"first": "http://localhost:8000/api/courses?page=1",
"last": "http://localhost:8000/api/courses?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"links": [
{
"url": null,
"label": "« Previous",
"active": false
},
{
"url": "http://localhost:8000/api/courses?page=1",
"label": 1,
"active": true
},
{
"url": null,
"label": "Next »",
"active": false
}
],
"path": "http://localhost:8000/api/courses",
"per_page": 10,
"to": 5,
"total": 5
}
}Single Course info
GET https://example.com/api/courses/{id}
{id} => id of an existing course (integer value only) This endpoint will return a single course matching the given "id" information if a valid accessToken is provided as a Bearer token You can use the login API to generate fresh accessToken
Headers
Name
Type
Description
Authorization
string
Bearer 7|vC2gUQC8ajaMOa2juAnaiE4ZLgmH5dcbCDY8Hwsy
Accept
string
application/json
Last updated
Was this helpful?