Set the Microsoft Teams channel rule
curl --request PUT \
--url https://api.statisfy.com/v1/integrations/microsoft_teams/channel-rule \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"prefix": "<string>",
"suffix": "<string>"
}
'import requests
url = "https://api.statisfy.com/v1/integrations/microsoft_teams/channel-rule"
payload = {
"prefix": "<string>",
"suffix": "<string>"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({prefix: '<string>', suffix: '<string>'})
};
fetch('https://api.statisfy.com/v1/integrations/microsoft_teams/channel-rule', 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.statisfy.com/v1/integrations/microsoft_teams/channel-rule",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'prefix' => '<string>',
'suffix' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/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.statisfy.com/v1/integrations/microsoft_teams/channel-rule"
payload := strings.NewReader("{\n \"prefix\": \"<string>\",\n \"suffix\": \"<string>\"\n}")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("Authorization", "Bearer <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))
}HttpResponse<String> response = Unirest.put("https://api.statisfy.com/v1/integrations/microsoft_teams/channel-rule")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"prefix\": \"<string>\",\n \"suffix\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.statisfy.com/v1/integrations/microsoft_teams/channel-rule")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"prefix\": \"<string>\",\n \"suffix\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"ingesting": 123,
"not_ingesting": 123,
"prefix": "<string>",
"suffix": "<string>"
}integrations
Set the Microsoft Teams channel rule
Saves the rule and applies it now to every Teams channel (not to group chats), which resets the changes made to single channels; after that, it decides each new channel. Send both values; an empty value is no rule. Teams need not be connected. Each value is 100 characters at most.
PUT
/
v1
/
integrations
/
microsoft_teams
/
channel-rule
Set the Microsoft Teams channel rule
curl --request PUT \
--url https://api.statisfy.com/v1/integrations/microsoft_teams/channel-rule \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"prefix": "<string>",
"suffix": "<string>"
}
'import requests
url = "https://api.statisfy.com/v1/integrations/microsoft_teams/channel-rule"
payload = {
"prefix": "<string>",
"suffix": "<string>"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({prefix: '<string>', suffix: '<string>'})
};
fetch('https://api.statisfy.com/v1/integrations/microsoft_teams/channel-rule', 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.statisfy.com/v1/integrations/microsoft_teams/channel-rule",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'prefix' => '<string>',
'suffix' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/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.statisfy.com/v1/integrations/microsoft_teams/channel-rule"
payload := strings.NewReader("{\n \"prefix\": \"<string>\",\n \"suffix\": \"<string>\"\n}")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("Authorization", "Bearer <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))
}HttpResponse<String> response = Unirest.put("https://api.statisfy.com/v1/integrations/microsoft_teams/channel-rule")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"prefix\": \"<string>\",\n \"suffix\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.statisfy.com/v1/integrations/microsoft_teams/channel-rule")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"prefix\": \"<string>\",\n \"suffix\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"ingesting": 123,
"not_ingesting": 123,
"prefix": "<string>",
"suffix": "<string>"
}Authorizations
An API key, sent as Authorization: Bearer stfy_live_…. See Authentication for how to get one and which scopes it needs.
Body
application/json
Response
200 - application/json
Successful Response
Was this page helpful?