Publish a project to the Community
Publish the project to the Community, or publish it again as it is now: a SNAPSHOT of the folders and items named — never what is in the Trash or not ready — copied into the Community, with the can…
curl -X POST https://api.auray.ai/v1/studio/projects/3f0c8a52-6a1d-4e8b-9c2d-7e5f4a3b2c1d/publication \
-H "Authorization: Bearer $AURAY_API_KEY" \
-H "content-type: application/json" \
-d '{
"folders": [
"all"
],
"items": [],
"canvases": [],
"title": "Night harbour",
"description": "A short about a lighthouse keeper.",
"category": "short",
"show_prompts": true,
"show_canvas": false,
"discoverable": true,
"show_spend": false,
"licence": true
}'const res = await fetch("https://api.auray.ai/v1/studio/projects/3f0c8a52-6a1d-4e8b-9c2d-7e5f4a3b2c1d/publication", {
method: "POST",
headers: {
Authorization: `Bearer ${process.env.AURAY_API_KEY}`,
"content-type": "application/json",
},
body: JSON.stringify({
"folders": [
"all"
],
"items": [],
"canvases": [],
"title": "Night harbour",
"description": "A short about a lighthouse keeper.",
"category": "short",
"show_prompts": true,
"show_canvas": false,
"discoverable": true,
"show_spend": false,
"licence": true
}),
});
console.log(await res.json());import os, requests
r = requests.post(
"https://api.auray.ai/v1/studio/projects/3f0c8a52-6a1d-4e8b-9c2d-7e5f4a3b2c1d/publication",
headers={"Authorization": f"Bearer {os.environ['AURAY_API_KEY']}"},
json={
"folders": [
"all"
],
"items": [],
"canvases": [],
"title": "Night harbour",
"description": "A short about a lighthouse keeper.",
"category": "short",
"show_prompts": True,
"show_canvas": False,
"discoverable": True,
"show_spend": False,
"licence": True
},
)
r.raise_for_status()
print(r.json())package main
import (
"bytes"
"fmt"
"io"
"net/http"
"os"
)
func main() {
body := []byte(`{
"folders": [
"all"
],
"items": [],
"canvases": [],
"title": "Night harbour",
"description": "A short about a lighthouse keeper.",
"category": "short",
"show_prompts": true,
"show_canvas": false,
"discoverable": true,
"show_spend": false,
"licence": true
}`)
req, err := http.NewRequest("POST", "https://api.auray.ai/v1/studio/projects/3f0c8a52-6a1d-4e8b-9c2d-7e5f4a3b2c1d/publication", bytes.NewReader(body))
if err != nil {
panic(err)
}
req.Header.Set("Authorization", "Bearer "+os.Getenv("AURAY_API_KEY"))
req.Header.Set("Content-Type", "application/json")
res, err := http.DefaultClient.Do(req)
if err != nil {
panic(err)
}
defer res.Body.Close()
out, _ := io.ReadAll(res.Body)
fmt.Println(res.Status, string(out))
}<?php
$ch = curl_init("https://api.auray.ai/v1/studio/projects/3f0c8a52-6a1d-4e8b-9c2d-7e5f4a3b2c1d/publication");
curl_setopt_array($ch, [
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => [
"Authorization: Bearer " . getenv("AURAY_API_KEY"),
"Content-Type: application/json",
],
CURLOPT_POSTFIELDS => json_encode([
"folders" => [
"all",
],
"items" => [],
"canvases" => [],
"title" => "Night harbour",
"description" => "A short about a lighthouse keeper.",
"category" => "short",
"show_prompts" => true,
"show_canvas" => false,
"discoverable" => true,
"show_spend" => false,
"licence" => true,
], JSON_UNESCAPED_SLASHES | JSON_UNESCAPED_UNICODE),
]);
$response = curl_exec($ch);
echo curl_getinfo($ch, CURLINFO_HTTP_CODE), " ", $response, PHP_EOL;require "net/http"
require "json"
uri = URI("https://api.auray.ai/v1/studio/projects/3f0c8a52-6a1d-4e8b-9c2d-7e5f4a3b2c1d/publication")
req = Net::HTTP::Post.new(uri)
req["Authorization"] = "Bearer #{ENV.fetch("AURAY_API_KEY")}"
req["Content-Type"] = "application/json"
req.body = {
"folders" => [
"all"
],
"items" => [],
"canvases" => [],
"title" => "Night harbour",
"description" => "A short about a lighthouse keeper.",
"category" => "short",
"show_prompts" => true,
"show_canvas" => false,
"discoverable" => true,
"show_spend" => false,
"licence" => true
}.to_json
res = Net::HTTP.start(uri.hostname, uri.port, use_ssl: true) { |http| http.request(req) }
puts res.code, res.bodyimport java.net.URI;
import java.net.http.HttpClient;
import java.net.http.HttpRequest;
import java.net.http.HttpResponse;
public class Main {
public static void main(String[] args) throws Exception {
String body = """
{
"folders": [
"all"
],
"items": [],
"canvases": [],
"title": "Night harbour",
"description": "A short about a lighthouse keeper.",
"category": "short",
"show_prompts": true,
"show_canvas": false,
"discoverable": true,
"show_spend": false,
"licence": true
}""";
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("https://api.auray.ai/v1/studio/projects/3f0c8a52-6a1d-4e8b-9c2d-7e5f4a3b2c1d/publication"))
.header("Authorization", "Bearer " + System.getenv("AURAY_API_KEY"))
.header("Content-Type", "application/json")
.method("POST", HttpRequest.BodyPublishers.ofString(body))
.build();
HttpResponse<String> response = HttpClient.newHttpClient()
.send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.statusCode() + " " + response.body());
}
}using System.Net.Http.Headers;
using System.Text;
using var client = new HttpClient();
client.DefaultRequestHeaders.Authorization =
new AuthenticationHeaderValue("Bearer", Environment.GetEnvironmentVariable("AURAY_API_KEY"));
using var request = new HttpRequestMessage(HttpMethod.Post, "https://api.auray.ai/v1/studio/projects/3f0c8a52-6a1d-4e8b-9c2d-7e5f4a3b2c1d/publication");
var body = """
{
"folders": [
"all"
],
"items": [],
"canvases": [],
"title": "Night harbour",
"description": "A short about a lighthouse keeper.",
"category": "short",
"show_prompts": true,
"show_canvas": false,
"discoverable": true,
"show_spend": false,
"licence": true
}
""";
request.Content = new StringContent(body, Encoding.UTF8, "application/json");
using var response = await client.SendAsync(request);
Console.WriteLine($"{(int)response.StatusCode} {await response.Content.ReadAsStringAsync()}");{
"object": "<string>",
"project_id": "<string>",
"publication_id": "<string>",
"url": "<string>",
"title": "<string>",
"description": "<string>",
"category": "<string>",
"toggles": {
"show_prompts": true,
"show_canvas": true,
"discoverable": true,
"show_spend": true
},
"selection": {
"folders": "<string[]>",
"items": "<string[]>",
"canvases": "<string[]>"
},
"items": 123,
"mine": true,
"standing": "<null or object>",
"fingerprint": "<string>",
"changed": true,
"copying": "<null or object>",
"published_at": "<string>",
"republished_at": "<string>",
"request_id": "<string>"
}{
"error": "<string>",
"message": "<string>",
"docs": "<string>",
"request_id": "<string>"
}{
"error": "<string>",
"message": "<string>",
"docs": "<string>",
"request_id": "<string>"
}{
"error": "<string>",
"message": "<string>",
"docs": "<string>",
"request_id": "<string>"
}{
"error": "<string>",
"message": "<string>",
"docs": "<string>",
"request_id": "<string>"
}{
"error": "<string>",
"message": "<string>",
"docs": "<string>",
"request_id": "<string>"
}{
"error": "<string>",
"message": "<string>",
"docs": "<string>",
"request_id": "<string>"
}{
"error": "<string>",
"message": "<string>",
"docs": "<string>",
"request_id": "<string>"
}{
"error": "<string>",
"message": "<string>",
"docs": "<string>",
"request_id": "<string>"
}{
"error": "<string>",
"message": "<string>",
"docs": "<string>",
"request_id": "<string>"
}{
"error": "<string>",
"message": "<string>",
"docs": "<string>",
"request_id": "<string>"
}{
"error": "<string>",
"message": "<string>",
"docs": "<string>",
"request_id": "<string>"
}{
"error": "<string>",
"message": "<string>",
"docs": "<string>",
"request_id": "<string>"
}Publish the project to the Community, or publish it again as it is now: a SNAPSHOT of the folders and items named — never what is in the Trash or not ready — copied into the Community, with the canvases named while show_canvas is on, only ever as a reader may see them. It is published under the owner's public profile, so only the project's owner may, with the licence ticked as for a single work and a Terms version that states it. Every word a stranger would read — title, description, the items' names, shown prompts and canvases — passes the automatic check first. On its page and the owner's profile once its files are copied (copying says how far); in the public feeds only once our team approves it. Publishing again copies beside the live snapshot and replaces it when done, back in our team's queue. A request copies what it has time for and the rest is finished in the background. Takes a key holding studio:write — Account offers it unticked — or the desktop's own session key. Spends nothing.
Authorizations
Bearer auray_sk_… — a key with the scope the route names.
Path Parameters
all, generations, uploads, or a member's folder by its id.show_canvas is on.canvases, read-only."film", "short", "series", "trailer", "commercial", "music_video", "animation", "documentary", "fashion", "game", "worldbuilding", "experimental", "other".true.Created.
"project_publication".GET /community/publications/{id}."film", "short", "series", "trailer", "commercial", "music_video", "animation", "documentary", "fashion", "game", "worldbuilding", "experimental", "other".Show child attributes
Show child attributes
changed compares it.Headers:
| Header | Description |
|---|---|
RateLimit-Limit | Burst capacity. |
RateLimit-Remaining | |
RateLimit-Reset | Seconds until refill. |
X-RateLimit-Limit | |
X-RateLimit-Remaining | |
X-RateLimit-Reset | Unix seconds. The X- spelling is what client libraries read. |
X-Request-Id |
Was this page helpful?
curl -X POST https://api.auray.ai/v1/studio/projects/3f0c8a52-6a1d-4e8b-9c2d-7e5f4a3b2c1d/publication \
-H "Authorization: Bearer $AURAY_API_KEY" \
-H "content-type: application/json" \
-d '{
"folders": [
"all"
],
"items": [],
"canvases": [],
"title": "Night harbour",
"description": "A short about a lighthouse keeper.",
"category": "short",
"show_prompts": true,
"show_canvas": false,
"discoverable": true,
"show_spend": false,
"licence": true
}'const res = await fetch("https://api.auray.ai/v1/studio/projects/3f0c8a52-6a1d-4e8b-9c2d-7e5f4a3b2c1d/publication", {
method: "POST",
headers: {
Authorization: `Bearer ${process.env.AURAY_API_KEY}`,
"content-type": "application/json",
},
body: JSON.stringify({
"folders": [
"all"
],
"items": [],
"canvases": [],
"title": "Night harbour",
"description": "A short about a lighthouse keeper.",
"category": "short",
"show_prompts": true,
"show_canvas": false,
"discoverable": true,
"show_spend": false,
"licence": true
}),
});
console.log(await res.json());import os, requests
r = requests.post(
"https://api.auray.ai/v1/studio/projects/3f0c8a52-6a1d-4e8b-9c2d-7e5f4a3b2c1d/publication",
headers={"Authorization": f"Bearer {os.environ['AURAY_API_KEY']}"},
json={
"folders": [
"all"
],
"items": [],
"canvases": [],
"title": "Night harbour",
"description": "A short about a lighthouse keeper.",
"category": "short",
"show_prompts": True,
"show_canvas": False,
"discoverable": True,
"show_spend": False,
"licence": True
},
)
r.raise_for_status()
print(r.json())package main
import (
"bytes"
"fmt"
"io"
"net/http"
"os"
)
func main() {
body := []byte(`{
"folders": [
"all"
],
"items": [],
"canvases": [],
"title": "Night harbour",
"description": "A short about a lighthouse keeper.",
"category": "short",
"show_prompts": true,
"show_canvas": false,
"discoverable": true,
"show_spend": false,
"licence": true
}`)
req, err := http.NewRequest("POST", "https://api.auray.ai/v1/studio/projects/3f0c8a52-6a1d-4e8b-9c2d-7e5f4a3b2c1d/publication", bytes.NewReader(body))
if err != nil {
panic(err)
}
req.Header.Set("Authorization", "Bearer "+os.Getenv("AURAY_API_KEY"))
req.Header.Set("Content-Type", "application/json")
res, err := http.DefaultClient.Do(req)
if err != nil {
panic(err)
}
defer res.Body.Close()
out, _ := io.ReadAll(res.Body)
fmt.Println(res.Status, string(out))
}<?php
$ch = curl_init("https://api.auray.ai/v1/studio/projects/3f0c8a52-6a1d-4e8b-9c2d-7e5f4a3b2c1d/publication");
curl_setopt_array($ch, [
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => [
"Authorization: Bearer " . getenv("AURAY_API_KEY"),
"Content-Type: application/json",
],
CURLOPT_POSTFIELDS => json_encode([
"folders" => [
"all",
],
"items" => [],
"canvases" => [],
"title" => "Night harbour",
"description" => "A short about a lighthouse keeper.",
"category" => "short",
"show_prompts" => true,
"show_canvas" => false,
"discoverable" => true,
"show_spend" => false,
"licence" => true,
], JSON_UNESCAPED_SLASHES | JSON_UNESCAPED_UNICODE),
]);
$response = curl_exec($ch);
echo curl_getinfo($ch, CURLINFO_HTTP_CODE), " ", $response, PHP_EOL;require "net/http"
require "json"
uri = URI("https://api.auray.ai/v1/studio/projects/3f0c8a52-6a1d-4e8b-9c2d-7e5f4a3b2c1d/publication")
req = Net::HTTP::Post.new(uri)
req["Authorization"] = "Bearer #{ENV.fetch("AURAY_API_KEY")}"
req["Content-Type"] = "application/json"
req.body = {
"folders" => [
"all"
],
"items" => [],
"canvases" => [],
"title" => "Night harbour",
"description" => "A short about a lighthouse keeper.",
"category" => "short",
"show_prompts" => true,
"show_canvas" => false,
"discoverable" => true,
"show_spend" => false,
"licence" => true
}.to_json
res = Net::HTTP.start(uri.hostname, uri.port, use_ssl: true) { |http| http.request(req) }
puts res.code, res.bodyimport java.net.URI;
import java.net.http.HttpClient;
import java.net.http.HttpRequest;
import java.net.http.HttpResponse;
public class Main {
public static void main(String[] args) throws Exception {
String body = """
{
"folders": [
"all"
],
"items": [],
"canvases": [],
"title": "Night harbour",
"description": "A short about a lighthouse keeper.",
"category": "short",
"show_prompts": true,
"show_canvas": false,
"discoverable": true,
"show_spend": false,
"licence": true
}""";
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("https://api.auray.ai/v1/studio/projects/3f0c8a52-6a1d-4e8b-9c2d-7e5f4a3b2c1d/publication"))
.header("Authorization", "Bearer " + System.getenv("AURAY_API_KEY"))
.header("Content-Type", "application/json")
.method("POST", HttpRequest.BodyPublishers.ofString(body))
.build();
HttpResponse<String> response = HttpClient.newHttpClient()
.send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.statusCode() + " " + response.body());
}
}using System.Net.Http.Headers;
using System.Text;
using var client = new HttpClient();
client.DefaultRequestHeaders.Authorization =
new AuthenticationHeaderValue("Bearer", Environment.GetEnvironmentVariable("AURAY_API_KEY"));
using var request = new HttpRequestMessage(HttpMethod.Post, "https://api.auray.ai/v1/studio/projects/3f0c8a52-6a1d-4e8b-9c2d-7e5f4a3b2c1d/publication");
var body = """
{
"folders": [
"all"
],
"items": [],
"canvases": [],
"title": "Night harbour",
"description": "A short about a lighthouse keeper.",
"category": "short",
"show_prompts": true,
"show_canvas": false,
"discoverable": true,
"show_spend": false,
"licence": true
}
""";
request.Content = new StringContent(body, Encoding.UTF8, "application/json");
using var response = await client.SendAsync(request);
Console.WriteLine($"{(int)response.StatusCode} {await response.Content.ReadAsStringAsync()}");{
"object": "<string>",
"project_id": "<string>",
"publication_id": "<string>",
"url": "<string>",
"title": "<string>",
"description": "<string>",
"category": "<string>",
"toggles": {
"show_prompts": true,
"show_canvas": true,
"discoverable": true,
"show_spend": true
},
"selection": {
"folders": "<string[]>",
"items": "<string[]>",
"canvases": "<string[]>"
},
"items": 123,
"mine": true,
"standing": "<null or object>",
"fingerprint": "<string>",
"changed": true,
"copying": "<null or object>",
"published_at": "<string>",
"republished_at": "<string>",
"request_id": "<string>"
}{
"error": "<string>",
"message": "<string>",
"docs": "<string>",
"request_id": "<string>"
}{
"error": "<string>",
"message": "<string>",
"docs": "<string>",
"request_id": "<string>"
}{
"error": "<string>",
"message": "<string>",
"docs": "<string>",
"request_id": "<string>"
}{
"error": "<string>",
"message": "<string>",
"docs": "<string>",
"request_id": "<string>"
}{
"error": "<string>",
"message": "<string>",
"docs": "<string>",
"request_id": "<string>"
}{
"error": "<string>",
"message": "<string>",
"docs": "<string>",
"request_id": "<string>"
}{
"error": "<string>",
"message": "<string>",
"docs": "<string>",
"request_id": "<string>"
}{
"error": "<string>",
"message": "<string>",
"docs": "<string>",
"request_id": "<string>"
}{
"error": "<string>",
"message": "<string>",
"docs": "<string>",
"request_id": "<string>"
}{
"error": "<string>",
"message": "<string>",
"docs": "<string>",
"request_id": "<string>"
}{
"error": "<string>",
"message": "<string>",
"docs": "<string>",
"request_id": "<string>"
}{
"error": "<string>",
"message": "<string>",
"docs": "<string>",
"request_id": "<string>"
}