curl --request PATCH \
--url https://api.member.dev/api/v1/conversations/{conversation_id}/audiences/me \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/vnd.api+json' \
--data '
{
"data": {
"attributes": {
"is_archived": true,
"is_muted": true,
"is_pinned": true
},
"type": "conversation_audiences"
}
}
'import requests
url = "https://api.member.dev/api/v1/conversations/{conversation_id}/audiences/me"
payload = { "data": {
"attributes": {
"is_archived": True,
"is_muted": True,
"is_pinned": True
},
"type": "conversation_audiences"
} }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/vnd.api+json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/vnd.api+json'},
body: JSON.stringify({
data: {
attributes: {is_archived: true, is_muted: true, is_pinned: true},
type: 'conversation_audiences'
}
})
};
fetch('https://api.member.dev/api/v1/conversations/{conversation_id}/audiences/me', 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://api.member.dev/api/v1/conversations/{conversation_id}/audiences/me",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
CURLOPT_POSTFIELDS => json_encode([
'data' => [
'attributes' => [
'is_archived' => true,
'is_muted' => true,
'is_pinned' => true
],
'type' => 'conversation_audiences'
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/vnd.api+json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.member.dev/api/v1/conversations/{conversation_id}/audiences/me"
payload := strings.NewReader("{\n \"data\": {\n \"attributes\": {\n \"is_archived\": true,\n \"is_muted\": true,\n \"is_pinned\": true\n },\n \"type\": \"conversation_audiences\"\n }\n}")
req, _ := http.NewRequest("PATCH", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/vnd.api+json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.patch("https://api.member.dev/api/v1/conversations/{conversation_id}/audiences/me")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/vnd.api+json")
.body("{\n \"data\": {\n \"attributes\": {\n \"is_archived\": true,\n \"is_muted\": true,\n \"is_pinned\": true\n },\n \"type\": \"conversation_audiences\"\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.member.dev/api/v1/conversations/{conversation_id}/audiences/me")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/vnd.api+json'
request.body = "{\n \"data\": {\n \"attributes\": {\n \"is_archived\": true,\n \"is_muted\": true,\n \"is_pinned\": true\n },\n \"type\": \"conversation_audiences\"\n }\n}"
response = http.request(request)
puts response.read_body{
"data": {
"attributes": {
"contact_id": "<string>",
"conversation_id": "<string>",
"display_name": "<string>",
"is_archived": true,
"is_muted": true,
"is_pinned": true,
"last_seen_at": "<string>",
"photo_url": "<string>",
"role": "<string>"
},
"id": "<string>",
"type": "<string>",
"links": {
"self": "<string>"
},
"meta": {},
"relationships": {}
},
"included": [
"<unknown>"
],
"links": {
"self": "<string>"
},
"meta": {}
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"ctx": {},
"input": "<unknown>"
}
]
}Update Own Audience State
Update the caller’s own pin/mute/archive state for a conversation.
Private per-member state — only affects the caller’s own view. Only the flags supplied in the request body are written (partial update); an all-omitted body is rejected as 422 by ConversationAudienceUpdateAttributes before this handler ever runs.
Returns 200 with the caller’s conversation_audiences resource (all three flags always included). Returns 403 conversation_access_denied when the caller is not an active member. 403 member_banned / member_not_in_hub on ban. 404 conversation_not_found when missing/soft-deleted. 422 pin_archived_conversation when the request would pin and archive in the same call. Requires Content-Type: application/vnd.api+json.
curl --request PATCH \
--url https://api.member.dev/api/v1/conversations/{conversation_id}/audiences/me \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/vnd.api+json' \
--data '
{
"data": {
"attributes": {
"is_archived": true,
"is_muted": true,
"is_pinned": true
},
"type": "conversation_audiences"
}
}
'import requests
url = "https://api.member.dev/api/v1/conversations/{conversation_id}/audiences/me"
payload = { "data": {
"attributes": {
"is_archived": True,
"is_muted": True,
"is_pinned": True
},
"type": "conversation_audiences"
} }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/vnd.api+json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/vnd.api+json'},
body: JSON.stringify({
data: {
attributes: {is_archived: true, is_muted: true, is_pinned: true},
type: 'conversation_audiences'
}
})
};
fetch('https://api.member.dev/api/v1/conversations/{conversation_id}/audiences/me', 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://api.member.dev/api/v1/conversations/{conversation_id}/audiences/me",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
CURLOPT_POSTFIELDS => json_encode([
'data' => [
'attributes' => [
'is_archived' => true,
'is_muted' => true,
'is_pinned' => true
],
'type' => 'conversation_audiences'
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/vnd.api+json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.member.dev/api/v1/conversations/{conversation_id}/audiences/me"
payload := strings.NewReader("{\n \"data\": {\n \"attributes\": {\n \"is_archived\": true,\n \"is_muted\": true,\n \"is_pinned\": true\n },\n \"type\": \"conversation_audiences\"\n }\n}")
req, _ := http.NewRequest("PATCH", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/vnd.api+json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.patch("https://api.member.dev/api/v1/conversations/{conversation_id}/audiences/me")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/vnd.api+json")
.body("{\n \"data\": {\n \"attributes\": {\n \"is_archived\": true,\n \"is_muted\": true,\n \"is_pinned\": true\n },\n \"type\": \"conversation_audiences\"\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.member.dev/api/v1/conversations/{conversation_id}/audiences/me")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/vnd.api+json'
request.body = "{\n \"data\": {\n \"attributes\": {\n \"is_archived\": true,\n \"is_muted\": true,\n \"is_pinned\": true\n },\n \"type\": \"conversation_audiences\"\n }\n}"
response = http.request(request)
puts response.read_body{
"data": {
"attributes": {
"contact_id": "<string>",
"conversation_id": "<string>",
"display_name": "<string>",
"is_archived": true,
"is_muted": true,
"is_pinned": true,
"last_seen_at": "<string>",
"photo_url": "<string>",
"role": "<string>"
},
"id": "<string>",
"type": "<string>",
"links": {
"self": "<string>"
},
"meta": {},
"relationships": {}
},
"included": [
"<unknown>"
],
"links": {
"self": "<string>"
},
"meta": {}
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"ctx": {},
"input": "<unknown>"
}
]
}Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Path Parameters
Body
JSON:API envelope for PATCH /api/conversations/{conversation_id}/audiences/me.
data.type must be 'conversation_audiences'. data.attributes carries any non-empty subset of is_pinned/is_muted/is_archived — at least one must be provided (see ConversationAudienceUpdateAttributes).
Show child attributes
Show child attributes