Skip to main content
GET
/
writer
/
writers-with-user-data
List all writers with linked user data merged in
curl --request GET \
  --url https://api.royalti.io/writer/writers-with-user-data \
  --header 'Authorization: Bearer <token>'
import requests

url = "https://api.royalti.io/writer/writers-with-user-data"

headers = {"Authorization": "Bearer <token>"}

response = requests.get(url, headers=headers)

print(response.text)
const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};

fetch('https://api.royalti.io/writer/writers-with-user-data', 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.royalti.io/writer/writers-with-user-data",
  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;
}
package main

import (
	"fmt"
	"net/http"
	"io"
)

func main() {

	url := "https://api.royalti.io/writer/writers-with-user-data"

	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(string(body))

}
HttpResponse<String> response = Unirest.get("https://api.royalti.io/writer/writers-with-user-data")
  .header("Authorization", "Bearer <token>")
  .asString();
require 'uri'
require 'net/http'

url = URI("https://api.royalti.io/writer/writers-with-user-data")

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_body
[
  {
    "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
    "tenantId": 123,
    "firstName": "<string>",
    "lastName": "<string>",
    "ipiNameNumber": "<string>",
    "ipiBaseNumber": "<string>",
    "affiliatedPRO": "<string>",
    "mrSociety": "<string>",
    "srSociety": "<string>",
    "generallyControlled": false,
    "canBeControlled": false,
    "publisherFee": 50,
    "saan": "<string>",
    "territories": [
      {
        "territoryCode": "WW",
        "prShare": 50,
        "mrShare": 50,
        "srShare": 50,
        "startDate": "2023-11-07T05:31:56Z",
        "endDate": "2023-11-07T05:31:56Z"
      }
    ],
    "settings": {},
    "tenantUserId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
    "userData": {
      "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
      "firstName": "<string>",
      "lastName": "<string>",
      "email": "jsmith@example.com",
      "ipi": "<string>"
    },
    "createdAt": "2023-11-07T05:31:56Z",
    "updatedAt": "2023-11-07T05:31:56Z",
    "firstNameSource": "user",
    "lastNameSource": "user",
    "ipiNameNumberSource": "user"
  }
]
This endpoint requires authentication. Include your Bearer token in the Authorization header.

Description

GET /writer/writers-with-user-data Description: Returns EVERY writer for the tenant (no pagination) with userData included. Where a writer’s own firstName/lastName/ipiNameNumber is blank, it is backfilled from the linked TenantUser and the corresponding *Source: 'user' marker field is added (e.g. firstNameSource) so callers can tell which fields were filled in from the account vs. entered directly on the writer record. Ordered by lastName, firstName ascending. Supports ?export=csv. Authorization:
  • Required role: user or higher
Method: GET

Code Examples

const response = await fetch('https://api.royalti.io/writer/writers-with-user-data', {
  method: 'GET',
  headers: {
    'Authorization': `Bearer ${token}`,
  },
});

const data = await response.json();
console.log(data);
import requests

response = requests.get(
  'https://api.royalti.io/writer/writers-with-user-data',
  headers={
    'Authorization': f'Bearer {token}'
  },
)

data = response.json()
print(data)
curl -X GET https://api.royalti.io/writer/writers-with-user-data \
  -H "Authorization: Bearer YOUR_TOKEN" \

Authorizations

Authorization
string
header
required

JWT Authorization header using the Bearer scheme. Format: "Bearer {token}"

Query Parameters

export
enum<string>
Available options:
csv

Response

Writers retrieved

id
string<uuid>
tenantId
integer
firstName
string
lastName
string
ipiNameNumber
string | null

11-digit CISAC IPI name number. Unique per tenant when set.

ipiBaseNumber
string | null

13-character CISAC IPI base number. Unique per tenant when set.

writerRole
enum<string>

CWR writer designation code. One of: CA (Composer & Author), C (Composer), A (Author/Lyricist), AR (Arranger), AD (Adaptor), TR (Translator), SR (Sub-Arranger), LY (Lyricist), CO (Composer), PA (Performer).

Available options:
CA,
C,
A,
AR,
AD,
TR,
SR,
LY,
CO,
PA
affiliatedPRO
string | null

Performing rights organization the writer is affiliated with (e.g. ASCAP, BMI). Free text — not enum-validated.

mrSociety
string | null
Maximum string length: 3
srSociety
string | null
Maximum string length: 3
generallyControlled
boolean
default:false
canBeControlled
boolean
default:false
publisherFee
number | null
Required range: 0 <= x <= 100
saan
string | null

Society-Assigned Agreement Number.

Maximum string length: 14
territories
object[]

Defaults to a single worldwide (WW) entry at 100% PR/MR/SR if omitted on create.

settings
object

Free-form writer settings (e.g. defaultTerritory, defaultShares). Not accepted via the create/update request bodies — set separately or defaulted to {}.

tenantUserId
string<uuid> | null
userData
object

Linked TenantUser account, included when the writer has a tenantUserId.

createdAt
string<date-time>
updatedAt
string<date-time>
firstNameSource
string
Example:

"user"

lastNameSource
string
Example:

"user"

ipiNameNumberSource
string
Example:

"user"