BUCKET
A bucket is a collection of phone numbers that can be uploaded, organized into an excel format
CREATE BUCKET
This endpoint allows you to create a bucket which contains all the phone numbers to be reached via sms.
POST
https://squadbygtco.com:8080/dashboard/bucketThis API creates SMS Bucket
Parameters
Body
name*
String
Name of Bucket
Description*
String
Description of Bucket
Cliet_id*
Integer
Unique client ID as pre-assigned
items*
object
Phone number and detail of each
Sample Request
{
"name": "nov2022",
"description": "November birthdays",
"client_id": 1,
"items": [
{
"phone_number": "07012345678",
"param1": "012"
},
{
"phone_number": "07012345678",
"param1": "012"
}
]
}
Responses
200:OK
Success{
"status": "CREATED",
"message": "bucket created successfully",
"data": {
"id": 2,
"name": "nov2022",
"description": "november birthdays",
"params": [
"phone_number",
"param1"
],
"client_id": 1,
"created_at": "2024-04-08T11:55:08.000Z",
"created_by": 1,
"updated_at": null,
"updated_by": null,
"bucket_items": 2
}
}
GET ALL CREATED BUCKETS
This endpoint allows you to retrieve created buckets
GET
https://squadbygtco.com:8080/dashboard/bucket/by-client/1?page=1&count=10This API retrieves all Bucket
Responses
200:OK
Success{
"status": "CREATED",
"message": "bucket created successfully",
"data": {
"id": 2,
"name": "nov2022",
"description": "november birthdays",
"params": [
"phone_number",
"param1"
],
"client_id": 1,
"created_at": "2024-04-08T11:55:08.000Z",
"created_by": 1,
"updated_at": null,
"updated_by": null,
"bucket_items": 2
}
}
UPDATE CREATED BUCKETS
This endpoint allows you to edit details for already created buckets. It allows editing the name of the bucket
POST
https://squadbygtco.com:8080/dashboard/bucketThis API creates SMS Bucket
Parameters
Body
name*
String
Name of Bucket
Description*
String
Description of Bucket
Cliet_id*
Integer
Unique client ID as pre-assigned
items*
object
Phone number and detail of each
Responses
200:OK
Success{
"message": "success",
"data": {
"id": 1,
"name": "nov2023_bucket",
"description": "november birthdays",
"params": [
"phone_number",
"param1"
],
"client_id": 1,
"created_at": "2024-02-29T11:22:51.000Z",
"created_by": 8,
"updated_at": "2024-04-08T12:47:21.000Z",
"updated_by": 1
}
}
Sample Request
{
"name":"nov2023_bucket"
}
DELETE CREATED BUCKETS
This endpoint allows you to delete a bucket
POST
https://squadbygtco.com:8080/dashboard/bucket/1This API deletes created Bucket
Responses
200:OK
Success{
"message": "success"
}