CustomerChatroomMember
Personen, mit denen das Mitglied einen Direktchat beginnen darf
GET/api/cp/chat/contacts
Geteilte aktuelle, bevorstehende oder kürzlich vergangene Veranstaltung (chatroom_member_direct_via_event, standardmäßig aktiv) oder geteilte Abteilung (chatroom_member_direct_via_department), ohne gesperrte Personen. Die Abfrage q filtert nach Name. Erfordert chatroom_member_direct_enabled (sonst 8618).
Query-Parameter
qstring | Teil des Namens |
Antworten
200Liste von {person_id, name, reasons}
curl --request GET \
--url https://eure-instanz.iw-erp.de/api/cp/chat/contacts \
--header 'x-iw-jwt-token: <TOKEN>'const options = {method: 'GET', headers: {'x-iw-jwt-token': '<TOKEN>'}};
fetch('https://eure-instanz.iw-erp.de/api/cp/chat/contacts', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://eure-instanz.iw-erp.de/api/cp/chat/contacts"
headers = {"x-iw-jwt-token": "<TOKEN>"}
response = requests.get(url, headers=headers)
print(response.text)<?php
require_once('vendor/autoload.php');
$client = new \GuzzleHttp\Client();
$response = $client->request('GET', 'https://eure-instanz.iw-erp.de/api/cp/chat/contacts', [
'headers' => [
'x-iw-jwt-token' => '<TOKEN>',
],
]);
echo $response->getBody();using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Get,
RequestUri = new Uri("https://eure-instanz.iw-erp.de/api/cp/chat/contacts"),
Headers =
{
{ "x-iw-jwt-token", "<TOKEN>" },
},
};
using (var response = await client.SendAsync(request))
{
response.EnsureSuccessStatusCode();
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}OkHttpClient client = new OkHttpClient();
Request request = new Request.Builder()
.url("https://eure-instanz.iw-erp.de/api/cp/chat/contacts")
.get()
.addHeader("x-iw-jwt-token", "<TOKEN>")
.build();
Response response = client.newCall(request).execute();package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://eure-instanz.iw-erp.de/api/cp/chat/contacts"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("x-iw-jwt-token", "<TOKEN>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}Dart mit dem Package iw_erp_api
import 'package:iw_erp_api/clients/customer_chat_member_controller.dart';
import 'package:iw_erp_api/logic/iw_api_state.dart';
IwApiState().host = 'eure-instanz.iw-erp.de';
IwApiState().currentJwtApiToken = '<TOKEN>';
final result = await CustomerChatMemberController.contacts();
if (result.success) {
print(result.data);
}Direkten Chat mit einer Person abrufen oder starten
POST/api/cp/chat/direct
Body: person (ID). Dieselben zwei Personen erhalten immer denselben Raum. Fehler: 8618 aus, 8621 keine gemeinsame Veranstaltung/Abteilung, 8622 gesperrt, 8623 Minderjährigenschutz ohne hinterlegte Eltern. Beim Minderjährigenschutz erhalten die Eltern des Minderjährigen bei einem Chat zwischen einem Erwachsenen und einem Minderjährigen die Leseberechtigung.
Request-Body application/json
personinteger
Antworten
200{id, token, name, member_started_type}
curl --request POST \
--url https://eure-instanz.iw-erp.de/api/cp/chat/direct \
--header 'content-type: application/json' \
--header 'x-iw-jwt-token: <TOKEN>' \
--data '{"person":1}'const options = {
method: 'POST',
headers: {'x-iw-jwt-token': '<TOKEN>', 'content-type': 'application/json'},
body: JSON.stringify({person: 1})
};
fetch('https://eure-instanz.iw-erp.de/api/cp/chat/direct', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://eure-instanz.iw-erp.de/api/cp/chat/direct"
payload = { "person": 1 }
headers = {
"x-iw-jwt-token": "<TOKEN>",
"content-type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)<?php
require_once('vendor/autoload.php');
$client = new \GuzzleHttp\Client();
$response = $client->request('POST', 'https://eure-instanz.iw-erp.de/api/cp/chat/direct', [
'body' => '{"person":1}',
'headers' => [
'content-type' => 'application/json',
'x-iw-jwt-token' => '<TOKEN>',
],
]);
echo $response->getBody();using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Post,
RequestUri = new Uri("https://eure-instanz.iw-erp.de/api/cp/chat/direct"),
Headers =
{
{ "x-iw-jwt-token", "<TOKEN>" },
},
Content = new StringContent("{\"person\":1}")
{
Headers =
{
ContentType = new MediaTypeHeaderValue("application/json")
}
}
};
using (var response = await client.SendAsync(request))
{
response.EnsureSuccessStatusCode();
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}OkHttpClient client = new OkHttpClient();
MediaType mediaType = MediaType.parse("application/json");
RequestBody body = RequestBody.create(mediaType, "{\"person\":1}");
Request request = new Request.Builder()
.url("https://eure-instanz.iw-erp.de/api/cp/chat/direct")
.post(body)
.addHeader("x-iw-jwt-token", "<TOKEN>")
.addHeader("content-type", "application/json")
.build();
Response response = client.newCall(request).execute();package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://eure-instanz.iw-erp.de/api/cp/chat/direct"
payload := strings.NewReader("{\"person\":1}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("x-iw-jwt-token", "<TOKEN>")
req.Header.Add("content-type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}Dart mit dem Package iw_erp_api
import 'package:iw_erp_api/clients/customer_chat_member_controller.dart';
import 'package:iw_erp_api/logic/iw_api_state.dart';
IwApiState().host = 'eure-instanz.iw-erp.de';
IwApiState().currentJwtApiToken = '<TOKEN>';
final result = await CustomerChatMemberController.startDirect(42);
if (result.success) {
print(result.data);
}Personen, die ein Trainer in eine Gruppe aufnehmen darf
GET/api/cp/chat/group_candidates
Angemeldete (nicht wartende) und leitende Personen der Veranstaltungen, die das Mitglied leitet (aktuelle, bevorstehende oder kürzlich vergangene). Erfordert chatroom_trainer_groups_enabled (sonst 8618); 8624 für Mitglieder, die keine Veranstaltung leiten.
Antworten
200Liste von {person_id, name, reasons}
curl --request GET \
--url https://eure-instanz.iw-erp.de/api/cp/chat/group_candidates \
--header 'x-iw-jwt-token: <TOKEN>'const options = {method: 'GET', headers: {'x-iw-jwt-token': '<TOKEN>'}};
fetch('https://eure-instanz.iw-erp.de/api/cp/chat/group_candidates', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://eure-instanz.iw-erp.de/api/cp/chat/group_candidates"
headers = {"x-iw-jwt-token": "<TOKEN>"}
response = requests.get(url, headers=headers)
print(response.text)<?php
require_once('vendor/autoload.php');
$client = new \GuzzleHttp\Client();
$response = $client->request('GET', 'https://eure-instanz.iw-erp.de/api/cp/chat/group_candidates', [
'headers' => [
'x-iw-jwt-token' => '<TOKEN>',
],
]);
echo $response->getBody();using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Get,
RequestUri = new Uri("https://eure-instanz.iw-erp.de/api/cp/chat/group_candidates"),
Headers =
{
{ "x-iw-jwt-token", "<TOKEN>" },
},
};
using (var response = await client.SendAsync(request))
{
response.EnsureSuccessStatusCode();
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}OkHttpClient client = new OkHttpClient();
Request request = new Request.Builder()
.url("https://eure-instanz.iw-erp.de/api/cp/chat/group_candidates")
.get()
.addHeader("x-iw-jwt-token", "<TOKEN>")
.build();
Response response = client.newCall(request).execute();package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://eure-instanz.iw-erp.de/api/cp/chat/group_candidates"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("x-iw-jwt-token", "<TOKEN>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}Dart mit dem Package iw_erp_api
import 'package:iw_erp_api/clients/customer_chat_member_controller.dart';
import 'package:iw_erp_api/logic/iw_api_state.dart';
IwApiState().host = 'eure-instanz.iw-erp.de';
IwApiState().currentJwtApiToken = '<TOKEN>';
final result = await CustomerChatMemberController.groupCandidates();
if (result.success) {
print(result.data);
}Einen Gruppenchat als Trainer starten
POST/api/cp/chat/group
Body: name (1–100 Zeichen), persons (IDs aus group_candidates, 1–100). Der Trainer ist Raum-Admin. Fehler: 8618 aus, 8624 kein Trainer, 8621 eine Person ist nicht in den Veranstaltungen des Trainers.
Request-Body application/json
namestringpersonsarray<integer>
Antworten
200{id, token, name, member_started_type}
curl --request POST \
--url https://eure-instanz.iw-erp.de/api/cp/chat/group \
--header 'content-type: application/json' \
--header 'x-iw-jwt-token: <TOKEN>' \
--data '
{
"name": "Beispiel",
"persons": [
1
]
}
'const options = {
method: 'POST',
headers: {'x-iw-jwt-token': '<TOKEN>', 'content-type': 'application/json'},
body: JSON.stringify({name: 'Beispiel', persons: [1]})
};
fetch('https://eure-instanz.iw-erp.de/api/cp/chat/group', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://eure-instanz.iw-erp.de/api/cp/chat/group"
payload = {
"name": "Beispiel",
"persons": [1]
}
headers = {
"x-iw-jwt-token": "<TOKEN>",
"content-type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)<?php
require_once('vendor/autoload.php');
$client = new \GuzzleHttp\Client();
$response = $client->request('POST', 'https://eure-instanz.iw-erp.de/api/cp/chat/group', [
'body' => '{"name":"Beispiel","persons":[1]}',
'headers' => [
'content-type' => 'application/json',
'x-iw-jwt-token' => '<TOKEN>',
],
]);
echo $response->getBody();using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Post,
RequestUri = new Uri("https://eure-instanz.iw-erp.de/api/cp/chat/group"),
Headers =
{
{ "x-iw-jwt-token", "<TOKEN>" },
},
Content = new StringContent("{\"name\":\"Beispiel\",\"persons\":[1]}")
{
Headers =
{
ContentType = new MediaTypeHeaderValue("application/json")
}
}
};
using (var response = await client.SendAsync(request))
{
response.EnsureSuccessStatusCode();
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}OkHttpClient client = new OkHttpClient();
MediaType mediaType = MediaType.parse("application/json");
RequestBody body = RequestBody.create(mediaType, "{\"name\":\"Beispiel\",\"persons\":[1]}");
Request request = new Request.Builder()
.url("https://eure-instanz.iw-erp.de/api/cp/chat/group")
.post(body)
.addHeader("x-iw-jwt-token", "<TOKEN>")
.addHeader("content-type", "application/json")
.build();
Response response = client.newCall(request).execute();package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://eure-instanz.iw-erp.de/api/cp/chat/group"
payload := strings.NewReader("{\"name\":\"Beispiel\",\"persons\":[1]}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("x-iw-jwt-token", "<TOKEN>")
req.Header.Add("content-type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}Dart mit dem Package iw_erp_api
import 'package:iw_erp_api/clients/customer_chat_member_controller.dart';
import 'package:iw_erp_api/logic/iw_api_state.dart';
IwApiState().host = 'eure-instanz.iw-erp.de';
IwApiState().currentJwtApiToken = '<TOKEN>';
final result = await CustomerChatMemberController.createGroup('…', [42]);
if (result.success) {
print(result.data);
}Eine Chat-Nachricht melden.
POST/api/cp/chat/chatroom_message/{identifier}/report
Body: reason (optional, bis zu 1000 Zeichen). Die Verwaltung sieht die Meldung in ihrer Warteschlange (Chat, Meldungen). Mit chatroom_ai_moderation_enabled wird eine ungeprüfte Nachricht nach der Antwort von der KI-Moderation geprüft. Nur Teilnehmer des Raums melden, nicht ihre eigenen Nachrichten; eine zweite Meldung derselben Person zur selben Nachricht aktualisiert die offene. Erfordert chatroom_message_report_enabled (sonst 8618).
Pfad-Parameter
identifierPflichtstring |
Request-Body application/json
reasonstring
Antworten
200{id, status}
curl --request POST \
--url https://eure-instanz.iw-erp.de/api/cp/chat/chatroom_message/42/report \
--header 'content-type: application/json' \
--header 'x-iw-jwt-token: <TOKEN>' \
--data '{"reason":"string"}'const options = {
method: 'POST',
headers: {'x-iw-jwt-token': '<TOKEN>', 'content-type': 'application/json'},
body: JSON.stringify({reason: 'string'})
};
fetch('https://eure-instanz.iw-erp.de/api/cp/chat/chatroom_message/42/report', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://eure-instanz.iw-erp.de/api/cp/chat/chatroom_message/42/report"
payload = { "reason": "string" }
headers = {
"x-iw-jwt-token": "<TOKEN>",
"content-type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)<?php
require_once('vendor/autoload.php');
$client = new \GuzzleHttp\Client();
$response = $client->request('POST', 'https://eure-instanz.iw-erp.de/api/cp/chat/chatroom_message/42/report', [
'body' => '{"reason":"string"}',
'headers' => [
'content-type' => 'application/json',
'x-iw-jwt-token' => '<TOKEN>',
],
]);
echo $response->getBody();using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Post,
RequestUri = new Uri("https://eure-instanz.iw-erp.de/api/cp/chat/chatroom_message/42/report"),
Headers =
{
{ "x-iw-jwt-token", "<TOKEN>" },
},
Content = new StringContent("{\"reason\":\"string\"}")
{
Headers =
{
ContentType = new MediaTypeHeaderValue("application/json")
}
}
};
using (var response = await client.SendAsync(request))
{
response.EnsureSuccessStatusCode();
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}OkHttpClient client = new OkHttpClient();
MediaType mediaType = MediaType.parse("application/json");
RequestBody body = RequestBody.create(mediaType, "{\"reason\":\"string\"}");
Request request = new Request.Builder()
.url("https://eure-instanz.iw-erp.de/api/cp/chat/chatroom_message/42/report")
.post(body)
.addHeader("x-iw-jwt-token", "<TOKEN>")
.addHeader("content-type", "application/json")
.build();
Response response = client.newCall(request).execute();package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://eure-instanz.iw-erp.de/api/cp/chat/chatroom_message/42/report"
payload := strings.NewReader("{\"reason\":\"string\"}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("x-iw-jwt-token", "<TOKEN>")
req.Header.Add("content-type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}Dart mit dem Package iw_erp_api
import 'package:iw_erp_api/clients/customer_chat_member_controller.dart';
import 'package:iw_erp_api/logic/iw_api_state.dart';
IwApiState().host = 'eure-instanz.iw-erp.de';
IwApiState().currentJwtApiToken = '<TOKEN>';
final result = await CustomerChatMemberController.report('42');
if (result.success) {
print(result.data);
}Die Personen, die das Mitglied blockiert hat
GET/api/cp/chat/blocks
Erfordert chatroom_block_enabled (sonst 8618).
Antworten
200Liste von {id, person_id, name, created}
curl --request GET \
--url https://eure-instanz.iw-erp.de/api/cp/chat/blocks \
--header 'x-iw-jwt-token: <TOKEN>'const options = {method: 'GET', headers: {'x-iw-jwt-token': '<TOKEN>'}};
fetch('https://eure-instanz.iw-erp.de/api/cp/chat/blocks', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://eure-instanz.iw-erp.de/api/cp/chat/blocks"
headers = {"x-iw-jwt-token": "<TOKEN>"}
response = requests.get(url, headers=headers)
print(response.text)<?php
require_once('vendor/autoload.php');
$client = new \GuzzleHttp\Client();
$response = $client->request('GET', 'https://eure-instanz.iw-erp.de/api/cp/chat/blocks', [
'headers' => [
'x-iw-jwt-token' => '<TOKEN>',
],
]);
echo $response->getBody();using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Get,
RequestUri = new Uri("https://eure-instanz.iw-erp.de/api/cp/chat/blocks"),
Headers =
{
{ "x-iw-jwt-token", "<TOKEN>" },
},
};
using (var response = await client.SendAsync(request))
{
response.EnsureSuccessStatusCode();
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}OkHttpClient client = new OkHttpClient();
Request request = new Request.Builder()
.url("https://eure-instanz.iw-erp.de/api/cp/chat/blocks")
.get()
.addHeader("x-iw-jwt-token", "<TOKEN>")
.build();
Response response = client.newCall(request).execute();package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://eure-instanz.iw-erp.de/api/cp/chat/blocks"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("x-iw-jwt-token", "<TOKEN>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}Dart mit dem Package iw_erp_api
import 'package:iw_erp_api/clients/customer_chat_member_controller.dart';
import 'package:iw_erp_api/logic/iw_api_state.dart';
IwApiState().host = 'eure-instanz.iw-erp.de';
IwApiState().currentJwtApiToken = '<TOKEN>';
final result = await CustomerChatMemberController.blocks();
if (result.success) {
print(result.data);
}Person sperren
POST/api/cp/chat/blocks
Body: person (ID). Keine Direktchats mehr in beide Richtungen, und die Nachrichten der Person sind für das Mitglied in allen Räumen ausgeblendet. Zweimaliges Sperren behält die erste Sperre. Erfordert chatroom_block_enabled (sonst 8618).
Request-Body application/json
personinteger
Antworten
200{id, person_id, name, created}
curl --request POST \
--url https://eure-instanz.iw-erp.de/api/cp/chat/blocks \
--header 'content-type: application/json' \
--header 'x-iw-jwt-token: <TOKEN>' \
--data '{"person":1}'const options = {
method: 'POST',
headers: {'x-iw-jwt-token': '<TOKEN>', 'content-type': 'application/json'},
body: JSON.stringify({person: 1})
};
fetch('https://eure-instanz.iw-erp.de/api/cp/chat/blocks', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://eure-instanz.iw-erp.de/api/cp/chat/blocks"
payload = { "person": 1 }
headers = {
"x-iw-jwt-token": "<TOKEN>",
"content-type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)<?php
require_once('vendor/autoload.php');
$client = new \GuzzleHttp\Client();
$response = $client->request('POST', 'https://eure-instanz.iw-erp.de/api/cp/chat/blocks', [
'body' => '{"person":1}',
'headers' => [
'content-type' => 'application/json',
'x-iw-jwt-token' => '<TOKEN>',
],
]);
echo $response->getBody();using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Post,
RequestUri = new Uri("https://eure-instanz.iw-erp.de/api/cp/chat/blocks"),
Headers =
{
{ "x-iw-jwt-token", "<TOKEN>" },
},
Content = new StringContent("{\"person\":1}")
{
Headers =
{
ContentType = new MediaTypeHeaderValue("application/json")
}
}
};
using (var response = await client.SendAsync(request))
{
response.EnsureSuccessStatusCode();
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}OkHttpClient client = new OkHttpClient();
MediaType mediaType = MediaType.parse("application/json");
RequestBody body = RequestBody.create(mediaType, "{\"person\":1}");
Request request = new Request.Builder()
.url("https://eure-instanz.iw-erp.de/api/cp/chat/blocks")
.post(body)
.addHeader("x-iw-jwt-token", "<TOKEN>")
.addHeader("content-type", "application/json")
.build();
Response response = client.newCall(request).execute();package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://eure-instanz.iw-erp.de/api/cp/chat/blocks"
payload := strings.NewReader("{\"person\":1}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("x-iw-jwt-token", "<TOKEN>")
req.Header.Add("content-type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}Dart mit dem Package iw_erp_api
import 'package:iw_erp_api/clients/customer_chat_member_controller.dart';
import 'package:iw_erp_api/logic/iw_api_state.dart';
IwApiState().host = 'eure-instanz.iw-erp.de';
IwApiState().currentJwtApiToken = '<TOKEN>';
final result = await CustomerChatMemberController.block(42);
if (result.success) {
print(result.data);
}Person entsperren
DELETE/api/cp/chat/blocks/{identifier}
Pfad-Parameter
identifierPflichtstring |
Antworten
200{removed: bool}
curl --request DELETE \
--url https://eure-instanz.iw-erp.de/api/cp/chat/blocks/42 \
--header 'x-iw-jwt-token: <TOKEN>'const options = {method: 'DELETE', headers: {'x-iw-jwt-token': '<TOKEN>'}};
fetch('https://eure-instanz.iw-erp.de/api/cp/chat/blocks/42', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://eure-instanz.iw-erp.de/api/cp/chat/blocks/42"
headers = {"x-iw-jwt-token": "<TOKEN>"}
response = requests.delete(url, headers=headers)
print(response.text)<?php
require_once('vendor/autoload.php');
$client = new \GuzzleHttp\Client();
$response = $client->request('DELETE', 'https://eure-instanz.iw-erp.de/api/cp/chat/blocks/42', [
'headers' => [
'x-iw-jwt-token' => '<TOKEN>',
],
]);
echo $response->getBody();using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Delete,
RequestUri = new Uri("https://eure-instanz.iw-erp.de/api/cp/chat/blocks/42"),
Headers =
{
{ "x-iw-jwt-token", "<TOKEN>" },
},
};
using (var response = await client.SendAsync(request))
{
response.EnsureSuccessStatusCode();
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}OkHttpClient client = new OkHttpClient();
Request request = new Request.Builder()
.url("https://eure-instanz.iw-erp.de/api/cp/chat/blocks/42")
.delete(null)
.addHeader("x-iw-jwt-token", "<TOKEN>")
.build();
Response response = client.newCall(request).execute();package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://eure-instanz.iw-erp.de/api/cp/chat/blocks/42"
req, _ := http.NewRequest("DELETE", url, nil)
req.Header.Add("x-iw-jwt-token", "<TOKEN>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}Dart mit dem Package iw_erp_api
import 'package:iw_erp_api/clients/customer_chat_member_controller.dart';
import 'package:iw_erp_api/logic/iw_api_state.dart';
IwApiState().host = 'eure-instanz.iw-erp.de';
IwApiState().currentJwtApiToken = '<TOKEN>';
final result = await CustomerChatMemberController.unblock(42);
if (result.success) {
print(result.data);
}