SupportChat
Vorhandenen Support-Chat abrufen
GET/api/public/chat/support
Header
x-public-session-tokenPflichtstring | Öffentlicher Sitzungstoken, der den Besucher identifiziert (alternativ übergebbar als Query-Parameter 'x-public-session-token' / 'ps_token' oder bei gesicherten Verbindungen als Cookie 'X-PUBLIC-SESSION-TOKEN') |
Antworten
default
Anfrage
curl --request GET \
--url https://eure-instanz.iw-erp.de/api/public/chat/supportconst options = {method: 'GET'};
fetch('https://eure-instanz.iw-erp.de/api/public/chat/support', 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/public/chat/support"
response = requests.get(url)
print(response.text)<?php
require_once('vendor/autoload.php');
$client = new \GuzzleHttp\Client();
$response = $client->request('GET', 'https://eure-instanz.iw-erp.de/api/public/chat/support');
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/public/chat/support"),
};
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/public/chat/support")
.get()
.build();
Response response = client.newCall(request).execute();package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://eure-instanz.iw-erp.de/api/public/chat/support"
req, _ := http.NewRequest("GET", url, nil)
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/public_chatroom_controller.dart';
import 'package:iw_erp_api/logic/iw_api_state.dart';
IwApiState().host = 'eure-instanz.iw-erp.de';
final result = await PublicChatroomController.getSupport();
if (result.success) {
print(result.data);
}Bestehenden Support-Chat starten oder abrufen
POST/api/public/chat/support
Header
x-public-session-tokenPflichtstring | Öffentlicher Sitzungstoken, der den Besucher identifiziert (alternativ übergebbar als Query-Parameter 'x-public-session-token' / 'ps_token' oder bei gesicherten Verbindungen als Cookie 'X-PUBLIC-SESSION-TOKEN') |
Request-Body application/json
messagestringErster Nachrichtentext
Antworten
200Support-Chatroom angelegt oder abgerufenobject
Felder anzeigen (4)
chatroomobjectparticipantobjectmessageobjectoffice_hoursobjectenabled, open, text (chatroom_support_office_hours_enabled)
Anfrage
curl --request POST \
--url https://eure-instanz.iw-erp.de/api/public/chat/support \
--header 'content-type: application/json' \
--data '{"message":"string"}'const options = {
method: 'POST',
headers: {'content-type': 'application/json'},
body: JSON.stringify({message: 'string'})
};
fetch('https://eure-instanz.iw-erp.de/api/public/chat/support', 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/public/chat/support"
payload = { "message": "string" }
headers = {"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/public/chat/support', [
'body' => '{"message":"string"}',
'headers' => [
'content-type' => 'application/json',
],
]);
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/public/chat/support"),
Content = new StringContent("{\"message\":\"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, "{\"message\":\"string\"}");
Request request = new Request.Builder()
.url("https://eure-instanz.iw-erp.de/api/public/chat/support")
.post(body)
.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/public/chat/support"
payload := strings.NewReader("{\"message\":\"string\"}")
req, _ := http.NewRequest("POST", url, payload)
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/public_chatroom_controller.dart';
import 'package:iw_erp_api/logic/iw_api_state.dart';
IwApiState().host = 'eure-instanz.iw-erp.de';
final result = await PublicChatroomController.postSupport('…');
if (result.success) {
print(result.data);
}Antwort 200 application/json
{}Nachrichten des Support-Chats abrufen
GET/api/public/chat/message
Query-Parameter
chatroomPflichtstring | Benachrichtigungs-Token des Chatraums |
afterIdinteger | Nachrichten nach dieser ID laden |
searchStringstring | Text, nach dem in der Liste gesucht wird |
orderFieldNamestring | Name des Bestellfelds |
orderFieldSortstring | SortiermodusErlaubt: DESCASC |
pageinteger | Seite der Liste |
pageSizeinteger | Anzahl der Einträge je Seite |
withMaxPageNumberstring | gibt die Anzahl verfügbarer Seiten als Header zurück, wenn dies gesetzt ist |
Header
x-public-session-tokenPflichtstring | Öffentlicher Sitzungstoken, der den Besucher identifiziert (alternativ übergebbar als Query-Parameter 'x-public-session-token' / 'ps_token' oder bei gesicherten Verbindungen als Cookie 'X-PUBLIC-SESSION-TOKEN') |
Antworten
default
Anfrage
curl --request GET \
--url 'https://eure-instanz.iw-erp.de/api/public/chat/message?chatroom=string'const options = {method: 'GET'};
fetch('https://eure-instanz.iw-erp.de/api/public/chat/message?chatroom=string', 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/public/chat/message?chatroom=string"
response = requests.get(url)
print(response.text)<?php
require_once('vendor/autoload.php');
$client = new \GuzzleHttp\Client();
$response = $client->request('GET', 'https://eure-instanz.iw-erp.de/api/public/chat/message?chatroom=string');
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/public/chat/message?chatroom=string"),
};
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/public/chat/message?chatroom=string")
.get()
.build();
Response response = client.newCall(request).execute();package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://eure-instanz.iw-erp.de/api/public/chat/message?chatroom=string"
req, _ := http.NewRequest("GET", url, nil)
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/public_chatroom_controller.dart';
import 'package:iw_erp_api/logic/iw_api_state.dart';
IwApiState().host = 'eure-instanz.iw-erp.de';
final result = await PublicChatroomController.getMessages(chatroomIdentifier: '…');
if (result.success) {
print(result.data);
}Sendet eine Nachricht in einem bestehenden Support-Chat
POST/api/public/chat/message
Header
x-public-session-tokenPflichtstring | Öffentlicher Sitzungstoken, der den Besucher identifiziert (alternativ übergebbar als Query-Parameter 'x-public-session-token' / 'ps_token' oder bei gesicherten Verbindungen als Cookie 'X-PUBLIC-SESSION-TOKEN') |
Request-Body application/json
chatroomstringBenachrichtigungs-Token des Chatraums
messagestringNachrichtentext
Antworten
default
Anfrage
curl --request POST \
--url https://eure-instanz.iw-erp.de/api/public/chat/message \
--header 'content-type: application/json' \
--data '
{
"chatroom": "string",
"message": "string"
}
'const options = {
method: 'POST',
headers: {'content-type': 'application/json'},
body: JSON.stringify({chatroom: 'string', message: 'string'})
};
fetch('https://eure-instanz.iw-erp.de/api/public/chat/message', 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/public/chat/message"
payload = {
"chatroom": "string",
"message": "string"
}
headers = {"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/public/chat/message', [
'body' => '{"chatroom":"string","message":"string"}',
'headers' => [
'content-type' => 'application/json',
],
]);
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/public/chat/message"),
Content = new StringContent("{\"chatroom\":\"string\",\"message\":\"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, "{\"chatroom\":\"string\",\"message\":\"string\"}");
Request request = new Request.Builder()
.url("https://eure-instanz.iw-erp.de/api/public/chat/message")
.post(body)
.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/public/chat/message"
payload := strings.NewReader("{\"chatroom\":\"string\",\"message\":\"string\"}")
req, _ := http.NewRequest("POST", url, payload)
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/public_chatroom_controller.dart';
import 'package:iw_erp_api/logic/iw_api_state.dart';
IwApiState().host = 'eure-instanz.iw-erp.de';
final result = await PublicChatroomController.postMessage(chatroomIdentifier: '…', message: '…');
if (result.success) {
print(result.data);
}