Create locker room post
curl --request POST \
--url https://app.d-sports.org/api/locker-room \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"content": "<string>",
"imageUrl": "<string>",
"teamId": "<string>",
"authorTeamId": "<string>",
"postAsTeamId": "<string>",
"scheduledFor": "2023-11-07T05:31:56Z",
"media": [
{}
],
"poll": {},
"collectible": {},
"lineup": {
"presetKey": "<string>",
"assignments": {},
"faces": [
"<string>"
]
}
}
'import requests
url = "https://app.d-sports.org/api/locker-room"
payload = {
"content": "<string>",
"imageUrl": "<string>",
"teamId": "<string>",
"authorTeamId": "<string>",
"postAsTeamId": "<string>",
"scheduledFor": "2023-11-07T05:31:56Z",
"media": [{}],
"poll": {},
"collectible": {},
"lineup": {
"presetKey": "<string>",
"assignments": {},
"faces": ["<string>"]
}
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
content: '<string>',
imageUrl: '<string>',
teamId: '<string>',
authorTeamId: '<string>',
postAsTeamId: '<string>',
scheduledFor: '2023-11-07T05:31:56Z',
media: [{}],
poll: {},
collectible: {},
lineup: {presetKey: '<string>', assignments: {}, faces: ['<string>']}
})
};
fetch('https://app.d-sports.org/api/locker-room', 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://app.d-sports.org/api/locker-room",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'content' => '<string>',
'imageUrl' => '<string>',
'teamId' => '<string>',
'authorTeamId' => '<string>',
'postAsTeamId' => '<string>',
'scheduledFor' => '2023-11-07T05:31:56Z',
'media' => [
[
]
],
'poll' => [
],
'collectible' => [
],
'lineup' => [
'presetKey' => '<string>',
'assignments' => [
],
'faces' => [
'<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://app.d-sports.org/api/locker-room"
payload := strings.NewReader("{\n \"content\": \"<string>\",\n \"imageUrl\": \"<string>\",\n \"teamId\": \"<string>\",\n \"authorTeamId\": \"<string>\",\n \"postAsTeamId\": \"<string>\",\n \"scheduledFor\": \"2023-11-07T05:31:56Z\",\n \"media\": [\n {}\n ],\n \"poll\": {},\n \"collectible\": {},\n \"lineup\": {\n \"presetKey\": \"<string>\",\n \"assignments\": {},\n \"faces\": [\n \"<string>\"\n ]\n }\n}")
req, _ := http.NewRequest("POST", 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.post("https://app.d-sports.org/api/locker-room")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"content\": \"<string>\",\n \"imageUrl\": \"<string>\",\n \"teamId\": \"<string>\",\n \"authorTeamId\": \"<string>\",\n \"postAsTeamId\": \"<string>\",\n \"scheduledFor\": \"2023-11-07T05:31:56Z\",\n \"media\": [\n {}\n ],\n \"poll\": {},\n \"collectible\": {},\n \"lineup\": {\n \"presetKey\": \"<string>\",\n \"assignments\": {},\n \"faces\": [\n \"<string>\"\n ]\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.d-sports.org/api/locker-room")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"content\": \"<string>\",\n \"imageUrl\": \"<string>\",\n \"teamId\": \"<string>\",\n \"authorTeamId\": \"<string>\",\n \"postAsTeamId\": \"<string>\",\n \"scheduledFor\": \"2023-11-07T05:31:56Z\",\n \"media\": [\n {}\n ],\n \"poll\": {},\n \"collectible\": {},\n \"lineup\": {\n \"presetKey\": \"<string>\",\n \"assignments\": {},\n \"faces\": [\n \"<string>\"\n ]\n }\n}"
response = http.request(request)
puts response.read_bodyLocker room
Create locker room post
Create a post. content may be empty when media, poll, collectible, or lineup is present. teamId is the about-tag. authorTeamId / postAsTeamId is who the post is authored as (403 if unauthorized). lineup is persisted: . Rejects with UGC_TERMS_REQUIRED when the caller’s ugcTermsVersion is missing or not equal to the current Terms of Use version.
POST
/
api
/
locker-room
Create locker room post
curl --request POST \
--url https://app.d-sports.org/api/locker-room \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"content": "<string>",
"imageUrl": "<string>",
"teamId": "<string>",
"authorTeamId": "<string>",
"postAsTeamId": "<string>",
"scheduledFor": "2023-11-07T05:31:56Z",
"media": [
{}
],
"poll": {},
"collectible": {},
"lineup": {
"presetKey": "<string>",
"assignments": {},
"faces": [
"<string>"
]
}
}
'import requests
url = "https://app.d-sports.org/api/locker-room"
payload = {
"content": "<string>",
"imageUrl": "<string>",
"teamId": "<string>",
"authorTeamId": "<string>",
"postAsTeamId": "<string>",
"scheduledFor": "2023-11-07T05:31:56Z",
"media": [{}],
"poll": {},
"collectible": {},
"lineup": {
"presetKey": "<string>",
"assignments": {},
"faces": ["<string>"]
}
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
content: '<string>',
imageUrl: '<string>',
teamId: '<string>',
authorTeamId: '<string>',
postAsTeamId: '<string>',
scheduledFor: '2023-11-07T05:31:56Z',
media: [{}],
poll: {},
collectible: {},
lineup: {presetKey: '<string>', assignments: {}, faces: ['<string>']}
})
};
fetch('https://app.d-sports.org/api/locker-room', 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://app.d-sports.org/api/locker-room",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'content' => '<string>',
'imageUrl' => '<string>',
'teamId' => '<string>',
'authorTeamId' => '<string>',
'postAsTeamId' => '<string>',
'scheduledFor' => '2023-11-07T05:31:56Z',
'media' => [
[
]
],
'poll' => [
],
'collectible' => [
],
'lineup' => [
'presetKey' => '<string>',
'assignments' => [
],
'faces' => [
'<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://app.d-sports.org/api/locker-room"
payload := strings.NewReader("{\n \"content\": \"<string>\",\n \"imageUrl\": \"<string>\",\n \"teamId\": \"<string>\",\n \"authorTeamId\": \"<string>\",\n \"postAsTeamId\": \"<string>\",\n \"scheduledFor\": \"2023-11-07T05:31:56Z\",\n \"media\": [\n {}\n ],\n \"poll\": {},\n \"collectible\": {},\n \"lineup\": {\n \"presetKey\": \"<string>\",\n \"assignments\": {},\n \"faces\": [\n \"<string>\"\n ]\n }\n}")
req, _ := http.NewRequest("POST", 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.post("https://app.d-sports.org/api/locker-room")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"content\": \"<string>\",\n \"imageUrl\": \"<string>\",\n \"teamId\": \"<string>\",\n \"authorTeamId\": \"<string>\",\n \"postAsTeamId\": \"<string>\",\n \"scheduledFor\": \"2023-11-07T05:31:56Z\",\n \"media\": [\n {}\n ],\n \"poll\": {},\n \"collectible\": {},\n \"lineup\": {\n \"presetKey\": \"<string>\",\n \"assignments\": {},\n \"faces\": [\n \"<string>\"\n ]\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.d-sports.org/api/locker-room")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"content\": \"<string>\",\n \"imageUrl\": \"<string>\",\n \"teamId\": \"<string>\",\n \"authorTeamId\": \"<string>\",\n \"postAsTeamId\": \"<string>\",\n \"scheduledFor\": \"2023-11-07T05:31:56Z\",\n \"media\": [\n {}\n ],\n \"poll\": {},\n \"collectible\": {},\n \"lineup\": {\n \"presetKey\": \"<string>\",\n \"assignments\": {},\n \"faces\": [\n \"<string>\"\n ]\n }\n}"
response = http.request(request)
puts response.read_bodyAuthorizations
Clerk session token. Use Authorization: Bearer .
Body
application/json
About-tag team
Post-as-team identity
Native alias for authorTeamId
Scheduled publish date (ISO 8601)
Available options:
public, private Formation builder attachment
Show child attributes
Show child attributes
Response
{ success, data }
Was this page helpful?
