contact-groups
curl --request GET \
--url https://swiftchats.axis96.xyz/api/contact-groups \
--header 'Authorization: Bearer <token>'import requests
url = "https://swiftchats.axis96.xyz/api/contact-groups"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://swiftchats.axis96.xyz/api/contact-groups', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://swiftchats.axis96.xyz/api/contact-groups",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://swiftchats.axis96.xyz/api/contact-groups"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://swiftchats.axis96.xyz/api/contact-groups")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://swiftchats.axis96.xyz/api/contact-groups")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"data": [
{
"id": 1,
"uuid": "c7c1ba3f-4abf-4516-9e2b-10b03a957254",
"organization_id": 7,
"name": "Leads1",
"created_by": 5,
"created_at": "2024-04-06T14:07:22.000000Z",
"updated_at": "2024-04-06T19:59:50.000000Z",
"deleted_at": null
},
{
"id": 3,
"uuid": "37a4ce08-6f2a-4cb2-bd2d-e724ce1508ed",
"organization_id": 7,
"name": "Lead 3",
"created_by": 0,
"created_at": "2024-04-09T10:53:36.000000Z",
"updated_at": "2024-04-09T10:53:36.000000Z",
"deleted_at": null
},
{
"id": 5,
"uuid": "2dc450a8-329a-47e0-82ed-66cdf1e8730f",
"organization_id": 7,
"name": "Lead 4",
"created_by": 0,
"created_at": "2024-04-09T13:32:24.000000Z",
"updated_at": "2024-04-09T13:32:24.000000Z",
"deleted_at": null
}
],
"links": {
"first": "http://whatsappsender.test/api/contact-groups?page=1",
"last": "http://whatsappsender.test/api/contact-groups?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"links": [
{
"url": null,
"label": "« Previous",
"active": false
},
{
"url": "http://whatsappsender.test/api/contact-groups?page=1",
"label": "1",
"active": true
},
{
"url": null,
"label": "Next »",
"active": false
}
],
"path": "http://whatsappsender.test/api/contact-groups",
"per_page": 10,
"to": 3,
"total": 3
}
}Contact Groups
Get Contact Group
GET
/
api
/
contact-groups
contact-groups
curl --request GET \
--url https://swiftchats.axis96.xyz/api/contact-groups \
--header 'Authorization: Bearer <token>'import requests
url = "https://swiftchats.axis96.xyz/api/contact-groups"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://swiftchats.axis96.xyz/api/contact-groups', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://swiftchats.axis96.xyz/api/contact-groups",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://swiftchats.axis96.xyz/api/contact-groups"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://swiftchats.axis96.xyz/api/contact-groups")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://swiftchats.axis96.xyz/api/contact-groups")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"data": [
{
"id": 1,
"uuid": "c7c1ba3f-4abf-4516-9e2b-10b03a957254",
"organization_id": 7,
"name": "Leads1",
"created_by": 5,
"created_at": "2024-04-06T14:07:22.000000Z",
"updated_at": "2024-04-06T19:59:50.000000Z",
"deleted_at": null
},
{
"id": 3,
"uuid": "37a4ce08-6f2a-4cb2-bd2d-e724ce1508ed",
"organization_id": 7,
"name": "Lead 3",
"created_by": 0,
"created_at": "2024-04-09T10:53:36.000000Z",
"updated_at": "2024-04-09T10:53:36.000000Z",
"deleted_at": null
},
{
"id": 5,
"uuid": "2dc450a8-329a-47e0-82ed-66cdf1e8730f",
"organization_id": 7,
"name": "Lead 4",
"created_by": 0,
"created_at": "2024-04-09T13:32:24.000000Z",
"updated_at": "2024-04-09T13:32:24.000000Z",
"deleted_at": null
}
],
"links": {
"first": "http://whatsappsender.test/api/contact-groups?page=1",
"last": "http://whatsappsender.test/api/contact-groups?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"links": [
{
"url": null,
"label": "« Previous",
"active": false
},
{
"url": "http://whatsappsender.test/api/contact-groups?page=1",
"label": "1",
"active": true
},
{
"url": null,
"label": "Next »",
"active": false
}
],
"path": "http://whatsappsender.test/api/contact-groups",
"per_page": 10,
"to": 3,
"total": 3
}
}Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Response
200 - application/json
OK
The response is of type object.
⌘I
