Get newsletter info by invite code
curl --request GET \
--url https://api.wsapi.chat/newsletters/invite/{code} \
--header 'X-Api-Key: <api-key>' \
--header 'X-Instance-Id: <x-instance-id>'import requests
url = "https://api.wsapi.chat/newsletters/invite/{code}"
headers = {
"X-Instance-Id": "<x-instance-id>",
"X-Api-Key": "<api-key>"
}
response = requests.get(url, headers=headers)
print(response.text)const options = {
method: 'GET',
headers: {'X-Instance-Id': '<x-instance-id>', 'X-Api-Key': '<api-key>'}
};
fetch('https://api.wsapi.chat/newsletters/invite/{code}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));using RestSharp;
var options = new RestClientOptions("https://api.wsapi.chat/newsletters/invite/{code}");
var client = new RestClient(options);
var request = new RestRequest("");
request.AddHeader("X-Instance-Id", "<x-instance-id>");
request.AddHeader("X-Api-Key", "<api-key>");
var response = await client.GetAsync(request);
Console.WriteLine("{0}", response.Content);
{
"id": "<string>",
"name": "<string>",
"description": "<string>",
"subscriberCount": 123,
"verificationState": "<string>",
"pictureUrl": "<string>",
"inviteCode": "<string>",
"role": "<string>",
"mute": "<string>",
"state": "<string>",
"createdAt": "2023-11-07T05:31:56Z"
}{
"status": 400,
"detail": "invalid request body"
}{
"status": 401,
"detail": "unauthorized"
}{
"status": 404,
"detail": "not found"
}{
"status": 409,
"detail": "device not paired"
}{
"status": 503,
"detail": "instance not available"
}Newsletters
Get newsletter info by invite code
Look up newsletter information using an invite code.
GET
/
newsletters
/
invite
/
{code}
Get newsletter info by invite code
curl --request GET \
--url https://api.wsapi.chat/newsletters/invite/{code} \
--header 'X-Api-Key: <api-key>' \
--header 'X-Instance-Id: <x-instance-id>'import requests
url = "https://api.wsapi.chat/newsletters/invite/{code}"
headers = {
"X-Instance-Id": "<x-instance-id>",
"X-Api-Key": "<api-key>"
}
response = requests.get(url, headers=headers)
print(response.text)const options = {
method: 'GET',
headers: {'X-Instance-Id': '<x-instance-id>', 'X-Api-Key': '<api-key>'}
};
fetch('https://api.wsapi.chat/newsletters/invite/{code}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));using RestSharp;
var options = new RestClientOptions("https://api.wsapi.chat/newsletters/invite/{code}");
var client = new RestClient(options);
var request = new RestRequest("");
request.AddHeader("X-Instance-Id", "<x-instance-id>");
request.AddHeader("X-Api-Key", "<api-key>");
var response = await client.GetAsync(request);
Console.WriteLine("{0}", response.Content);
{
"id": "<string>",
"name": "<string>",
"description": "<string>",
"subscriberCount": 123,
"verificationState": "<string>",
"pictureUrl": "<string>",
"inviteCode": "<string>",
"role": "<string>",
"mute": "<string>",
"state": "<string>",
"createdAt": "2023-11-07T05:31:56Z"
}{
"status": 400,
"detail": "invalid request body"
}{
"status": 401,
"detail": "unauthorized"
}{
"status": 404,
"detail": "not found"
}{
"status": 409,
"detail": "device not paired"
}{
"status": 503,
"detail": "instance not available"
}Authorizations
Response
Newsletter info
⌘I