List reference sets
Viewing v2— current version
curl --request GET \ --url https://api.app.layer.ai/api/v2/workspaces/:workspace_id/reference-sets \ --header 'Authorization: Bearer <token>'import requests
url = "https://api.app.layer.ai/api/v2/workspaces/:workspace_id/reference-sets"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.json())const url = 'https://api.app.layer.ai/api/v2/workspaces/:workspace_id/reference-sets';const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}package main
import ( "fmt" "net/http" "io")
func main() {
url := "https://api.app.layer.ai/api/v2/workspaces/:workspace_id/reference-sets"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close() body, _ := io.ReadAll(res.Body)
fmt.Println(res) fmt.Println(string(body))
}<?php
$curl = curl_init();
curl_setopt_array($curl, [ CURLOPT_URL => "https://api.app.layer.ai/api/v2/workspaces/:workspace_id/reference-sets", CURLOPT_RETURNTRANSFER => true, CURLOPT_ENCODING => "", CURLOPT_MAXREDIRS => 10, CURLOPT_TIMEOUT => 30, CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, CURLOPT_CUSTOMREQUEST => "GET", CURLOPT_HTTPHEADER => [ "Authorization: Bearer <token>" ],]);
$response = curl_exec($curl);$err = curl_error($curl);
curl_close($curl);
if ($err) { echo "cURL Error #:" . $err;} else { echo $response;}OkHttpClient client = new OkHttpClient();
Request request = new Request.Builder() .url("https://api.app.layer.ai/api/v2/workspaces/:workspace_id/reference-sets") .get() .addHeader("Authorization", "Bearer <token>") .build();
Response response = client.newCall(request).execute();require 'uri'require 'net/http'
url = URI("https://api.app.layer.ai/api/v2/workspaces/:workspace_id/reference-sets")
http = Net::HTTP.new(url.host, url.port)http.use_ssl = true
request = Net::HTTP::Get.new(url)request["Authorization"] = 'Bearer <token>'
response = http.request(request)puts response.read_bodyvar client = new RestClient("https://api.app.layer.ai/api/v2/workspaces/:workspace_id/reference-sets");var request = new RestRequest("", Method.Get);request.AddHeader("Authorization", "Bearer <token>");var response = client.Execute(request);New in v2. This endpoint has no v1 equivalent.
List the workspace’s reference sets. Pass a returned reference_set_id in the reference_sets array of an inference request. Only sets that are ready to generate with are listed: archived sets, and empty ones with no files, no trained model and no prompt fragments, are omitted.
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”Id of the workspace that owns the resource.
Id of the workspace that owns the resource.
Query Parameters
Section titled “Query Parameters”Full-text search on name/description
Full-text search on name/description
What a reference set is.
The first group is user-settable: a curator picks one when creating or editing a set.
The second group is internal: the cinematic-technique library owns those values, they
are seeded only by the fixtures in core/workflows/fixtures/data/reference_sets and
a user-facing write path must reject them (see USER_SETTABLE_CATEGORIES).
Only sets of this category, e.g. animation for the motions a rigged mesh can play.
Maximum number of results to return.
Maximum number of results to return.
Cursor from a previous response to fetch the next page.
Cursor from a previous response to fetch the next page.
Responses
Section titled “Responses”Successful Response
object
object
Reference set identifier — pass it in reference_sets.
Display name of the reference set.
What a reference set is.
The first group is user-settable: a curator picks one when creating or editing a set.
The second group is internal: the cinematic-technique library owns those values, they
are seeded only by the fixtures in core/workflows/fixtures/data/reference_sets and
a user-facing write path must reject them (see USER_SETTABLE_CATEGORIES).
True when the set has a trained custom model.
object
Cursor to use to get the next page
If there are more results to page through
Total number of results matching the query
Example
{ "reference_sets": [ { "category": "general" } ]}Unauthenticated — missing or invalid Bearer token.
object
Example
{ "type": "https://api.layer.ai/errors/ERROR_CODE", "title": "Error Title", "status": 400, "detail": "Human-readable description."}Forbidden — insufficient permissions, or the access token lacks the scope the operation requires.
object
Example
{ "type": "https://api.layer.ai/errors/ERROR_CODE", "title": "Error Title", "status": 400, "detail": "Human-readable description."}Resource not found.
object
Example
{ "type": "https://api.layer.ai/errors/ERROR_CODE", "title": "Error Title", "status": 400, "detail": "Human-readable description."}The outcome of the request with this Idempotency-Key is not known yet: it is still running, or it failed without a stored response. Retry after the number of seconds in Retry-After.
object
Example
{ "type": "https://api.layer.ai/errors/ERROR_CODE", "title": "Error Title", "status": 400, "detail": "Human-readable description."}Invalid input parameters, or an Idempotency-Key reused for a different request.
object
Example
{ "type": "https://api.layer.ai/errors/ERROR_CODE", "title": "Error Title", "status": 400, "detail": "Human-readable description."}Rate limited — retry after the number of seconds in Retry-After.
object
Example
{ "type": "https://api.layer.ai/errors/ERROR_CODE", "title": "Error Title", "status": 400, "detail": "Human-readable description."}Internal server error.
object
Example
{ "type": "https://api.layer.ai/errors/ERROR_CODE", "title": "Error Title", "status": 400, "detail": "Human-readable description."}