TheirStory provides a web-based interviewing and storytelling platform that helps families and organizations collect and make accessible audiovisual oral histories. This API guide details how to interact with the TheirStory API to access user information and associated features.
The API uses JWT (JSON Web Tokens) for authentication. Tokens are returned in API responses and should be included in subsequent requests.
Authenticates a user and returns user information along with an access token.
https://node.theirstory.io/signin
The request should include user credentials in JSON format.
{
"email": "user@example.com",
"password": "yourpassword"
}
The response includes a JWT token and detailed information about the authenticated user.
token
: JWT authentication tokenfull_name
: User's full nameuser_id
: Unique identifier for the userrole
: User's role in the system (e.g., "admin")email
: User's email addressuser_details
: Detailed information about the user's profileorganization_info
: Information about the user's organizationapi_version
: Version of the APIcreate_gallery
: Boolean permission for gallery creation{
"token": "eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwiaHR0cHM6Ly90aGVpcnN0b3J5LmlvL3Zpc2l0b3ItaWQiOiIwYWIxMmNkMy00NTY3LTg5MDEtMjM0NS02N2FiOGNkZTkwZjEiLCJpYXQiOjE2MjM0NTY3ODl9.AbCdEfGhIjKlMnOpQrStUvWxYz",
"full_name": "John Doe",
"user_id": "1234567890abcdef",
"role": "admin",
"email": "user@example.com",
"user_details": {
"id": 12345,
"email": "user@example.com",
"first_name": "John",
"last_name": "Doe",
"photo_file_name": null,
"photo_content_type": null,
"organizations": [
{
"id": 67,
"name": "Example Organization",
"subdomain": "example",
"custom_domain": "",
"description": "Example Organization is a platform that helps collect and preserve stories through interviews.
",
"addresses": [
{
"address_line_1": "123 Main Street",
"address_line_2": "",
"city": "Anytown",
"state": "NY",
"zipcode": "12345",
"country": "US"
}
]
}
]
},
"organization_info": {
"permanent_org": {
"export_allowed": true,
"archive_nbr": "01ab-2345"
},
"settings": {
"transcription_service": "cloudconvert",
"filler_words": false,
"vocabulary": [],
"auto_chaptering": true,
"summary_prompt": "Create a concise summary of this interview focusing on key topics discussed.",
"chaptering_prompt": "Create an index for this interview with timecodes, titles, summaries, and keywords."
},
"branding": false,
"_id": "abcdef1234567890",
"activity": true,
"org_manager_view_all": true,
"export_allowed": true,
"require_session_passwords": false,
"local_recordings_allowed": true,
"groups": [
"group123",
"group456",
"group789"
],
"organization_name": "Example Admin",
"organizational_code": "example_admin_123456",
"created_at": "2023-01-15T12:30:45.678Z",
"__v": 5,
"allow_dial_in": true,
"local_recordings_polyfill": false,
"credits": 1000000,
"maxProjectsAllowed": 200,
"projects": 150,
"recording_hours": 320,
"backgroundUrl": "uploads/projectbackgrounds/example-background-image.jpg"
},
"api_version": "1.2.3",
"create_gallery": true
}
fetch('https://node.theirstory.io/signin', {
method: 'POST',
headers: {
'Content-Type': 'application/json',
'Accept': 'application/json, text/plain, */*'
},
body: JSON.stringify({
email: email,
password: password
})
})
.then(response => {
if (response.ok) {
return response.json();
}
throw new Error('Login failed');
})
.then(data => {
showMessage('Login successful! Redirecting...', 'success');
// Store the token in localStorage for use in the organizations page
localStorage.setItem('authToken', data.token);
// Redirect to the front page
setTimeout(() => {
window.location.href = 'frontpage.html';
}, 1500);
})
.catch(error => {
showMessage('Login failed. Please check your credentials.', 'error');
console.error('Error:', error);
});
Retrieves information about the currently authenticated user.
https://node.theirstory.io/current_user
visitorId
(required): Unique identifier for the visitor/sessionhttps://node.theirstory.io/current_user?visitorId=7fe32a19-84c5-4921-b517-29d7c8e54f3a
The response includes detailed information about the user, their role, associated organizations, and feature access.
token
: JWT authentication tokenfull_name
: User's full nameuser_id
: Unique identifier for the userrole
: User's role in the system (e.g., "admin")email
: User's email addressuser_details
: Detailed information about the user's profile
id
: User IDemail
: User's emailfirst_name
: User's first namelast_name
: User's last namephoto_file_name
: Optional filename for user's photophoto_content_type
: Media type of user's photoorganizations
: List of organizations the user belongs to
id
: Organization IDname
: Organization namesubdomain
: Organization subdomaincustom_domain
: Optional custom domaindescription
: HTML description of the organizationaddresses
: Physical addresses associated with the organizationorganization_info
: Information about the user's organization
permanent_org
: Permanent organization detailssettings
: Organization-specific settings
transcription_service
: Service used for transcriptionfiller_words
: Boolean to include/exclude filler words in transcriptionvocabulary
: Custom vocabulary for transcriptionauto_chaptering
: Boolean for automatic chapter creationsummary_prompt
: Prompt used for generating summarieschaptering_prompt
: Prompt used for generating chaptersbranding
: Boolean for custom brandingactivity
: Boolean for activity trackingorg_manager_view_all
: Permission setting for organization managersexport_allowed
: Boolean for export permissionrequire_session_passwords
: Boolean for session password requirementlocal_recordings_allowed
: Boolean for local recording permissiongroups
: List of group IDsorganization_name
: Name of the organizationorganizational_code
: Unique code for the organizationcredits
: Available creditsmaxProjectsAllowed
: Maximum number of allowed projectsprojects
: Current number of projectsrecording_hours
: Hours of recordingsapi_version
: Version of the APIcreate_gallery
: Boolean permission for gallery creation{
"token": "eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiI4NDc2MjkzOTQ4NjMzIiwiaHR0cHM6Ly90aGVpcnN0b3J5LmlvL3Zpc2l0b3ItaWQiOiI3ZmUzMmExOS04NGM1LTQ5MjEtYjUxNy0yOWQ3YzhlNTRmM2EiLCJpYXQiOjE3MzM0ODUyMDF9.AoBg5ub7DvhJxYz8KpLn",
"full_name": "Jane Smith",
"user_id": "847629394863",
"role": "admin",
"email": "jane.smith@example.com",
"user_details": {
"id": 12345,
"email": "jane.smith@example.com",
"first_name": "Jane",
"last_name": "Smith",
"photo_file_name": null,
"photo_content_type": null,
"organizations": [
{
"id": 78,
"name": "Community Archives Project",
"subdomain": "communityarchives",
"custom_domain": "",
"description": "The Community Archives Project collects and preserves local stories through audio and video interviews.
",
"addresses": [
{
"address_line_1": "123 Main Street",
"address_line_2": "Suite 405",
"city": "Riverdale",
"state": "NY",
"zipcode": "10463",
"country": "US"
}
]
},
{
"id": 92,
"name": "Metro Historical Society",
"subdomain": "metrohistory",
"custom_domain": "",
"description": "The Metro Historical Society works to document and preserve the cultural heritage of our city's diverse communities.
",
"addresses": [
{
"address_line_1": "456 Heritage Avenue",
"address_line_2": "",
"city": "Metro City",
"state": "CA",
"zipcode": "90210",
"country": "US"
}
]
}
]
},
"organization_info": {
"permanent_org": {
"export_allowed": true,
"archive_nbr": "07kp-2341"
},
"settings": {
"transcription_service": "cloudconvert",
"filler_words": false,
"vocabulary": ["genealogy", "archives", "cultural heritage"],
"auto_chaptering": true,
"summary_prompt": "Create a concise summary of this oral history interview focusing on the key topics, historical events, and personal experiences discussed.",
"chaptering_prompt": "Divide this interview into logical chapters based on topic changes and significant moments. Each chapter should include a timecode, title, brief summary, and relevant keywords."
},
"branding": true,
"_id": "6ab92cd3e7f14502937654a2",
"activity": true,
"org_manager_view_all": true,
"aviary_export_allowed": true,
"require_session_passwords": true,
"local_recordings_allowed": true,
"groups": [
"7ac892d3f4e25613ba98765c",
"8bd903e4g5f36724cb09876d",
"9ce014f5h6g47835dc10987e"
],
"organization_name": "Community Archives Admin",
"organizational_code": "ca_admin_854237",
"created_at": "2023-04-15T14:27:42.519Z",
"__v": 5,
"allow_dial_in": true,
"local_recordings_polyfill": false,
"credits": 1750000,
"maxProjectsAllowed": 300,
"projects": 187,
"recording_hours": 428,
"backgroundUrl": "uploads/projectbackgrounds/KpL8sMnO7qRtUvWxYz9A.jpg"
},
"api_version": "2.7.4",
"create_gallery": true
}
Retrieves information about projects the user has access to.
https://node.theirstory.io/projects
The response is an array of project objects with details about each project.
_id
: Unique identifier for the projectname
: Name of the projectdescription
: Description of the projectcreator
: ID of the user who created the projectbackgroundUrl
: Path to the background imagedisplayTitle
: Boolean indicating if the title should be displayeddefaultProjectForOrganization
: Boolean indicating if this is the default projectorganization
: Organization ID that owns the projectcreated_at
: Timestamp of when the project was created__v
: Version numberview_only_code
: Code for view-only accessview_only_code_created_at
: Timestamp when view-only code was createdmember_code
: Code for member accessmember_code_created_at
: Timestamp when member code was createdproject_manager_code
: Code for project manager accessproject_manager_code_created_at
: Timestamp when project manager code was createdprojectBackgroundUrl
: Full URL to the background imagefolders
: Array of folder objects belonging to the project
_id
: Unique identifier for the foldername
: Name of the foldercreator
: ID of the user who created the folderproject
: Project ID the folder belongs todefaultFolderForProject
: Boolean indicating if this is the default foldercreated_at
: Timestamp of when the folder was created__v
: Version numberfu
: Array of folder user objects
_id
: Unique identifier for the folder user relationshipuser
: User IDaccepted
: Boolean indicating if the user accepted the folder invitationcreator
: Boolean indicating if the user is the creatorfolder
: Folder IDcreated_at
: Timestamp when the relationship was created__v
: Version numberorganizationName
: Name of the organization the project belongs tostoriesInProject
: Count of stories in the projectisManager
: Boolean indicating if the current user is a manager of this project[
{
"_id": "proj123456789",
"name": "Community Archives",
"description": "Archive of local community stories and interviews",
"creator": "user987654321",
"backgroundUrl": "uploads/projectbackgrounds/community-archives-bg.jpg",
"displayTitle": true,
"defaultProjectForOrganization": false,
"organization": "org123456789",
"created_at": "2024-01-15T14:26:14.086Z",
"__v": 0,
"view_only_code": "aBcD1234EfGh5i6",
"view_only_code_created_at": "2024-01-15T14:26:58.682Z",
"member_code": "jKlM7890nOpQ1r2",
"member_code_created_at": "2024-01-15T14:26:58.987Z",
"project_manager_code": "sTuV3456wXyZ7a8",
"project_manager_code_created_at": "2024-10-15T14:30:21.837Z",
"projectBackgroundUrl": "https://storage.example.com/uploads/projectbackgrounds/community-archives-bg.jpg?token=abc123",
"folders": [
{
"_id": "fold123456789",
"name": "Senior Interviews",
"creator": "user987654321",
"project": "proj123456789",
"defaultFolderForProject": false,
"created_at": "2024-01-20T12:57:05.461Z",
"__v": 0,
"fu": [
{
"_id": "foldu123456789",
"user": "user987654321",
"accepted": true,
"creator": true,
"folder": "fold123456789",
"created_at": "2024-01-20T12:57:05.484Z",
"__v": 0
}
]
}
],
"organizationName": "Community Archives Organization",
"storiesInProject": 32,
"isManager": true
},
{
"_id": "proj987654321",
"name": "Oral History Collection",
"description": "Collection of oral histories from community members",
"creator": "user123456789",
"backgroundUrl": "uploads/projectbackgrounds/oral-history-bg.jpg",
"displayTitle": true,
"defaultProjectForOrganization": false,
"organization": "org987654321",
"created_at": "2024-02-10T19:08:14.209Z",
"__v": 0,
"view_only_code": "bCdE2345fGhI6j7",
"view_only_code_created_at": "2024-02-10T19:36:20.241Z",
"member_code": "kLmN8901oPqR2s3",
"member_code_created_at": "2024-02-25T15:50:06.822Z",
"projectBackgroundUrl": "https://storage.example.com/uploads/projectbackgrounds/oral-history-bg.jpg?token=def456",
"folders": [],
"organizationName": "Oral History Foundation",
"storiesInProject": 18,
"isManager": false
}
]
Retrieves information about organizations that the user has access to.
https://node.theirstory.io/organization
The response includes an array of organization objects with details about each organization the user has access to.
organizations
: Array of organization objects, each containing:
_id
: Unique identifier for the organizationactivity
: Boolean indicating if the organization is activeorg_manager_view_all
: Boolean controlling manager view permissionsexport_allowed
: Boolean for export permissionrequire_session_passwords
: Boolean for session password requirementgroups
: Array of group IDsorganization_name
: Name of the organizationorganizational_code
: Unique code for the organizationcreated_at
: Creation timestamp__v
: Version numberlocal_recordings_polyfill
: Boolean to enable recording polyfillallow_dial_in
: Boolean to allow dial-in functionalitylocal_recordings_allowed
: Boolean for local recording permissionpermanent_org
: Object with organization permanence detailscredits
: Available creditsbackgroundUrl
: URL to the organization's background imagemaxProjectsAllowed
: Maximum number of allowed projectsprojects
: Current number of projectsrecording_hours
: Available recording hoursbranding
: Boolean for custom brandingsettings
: Object with organization settings
transcription_service
: Service used for transcriptionfiller_words
: Boolean to include/exclude filler wordsvocabulary
: Array of custom vocabulary wordsauto_chaptering
: Boolean for automatic chapter creationsummary_prompt
: Prompt for summary generationchaptering_prompt
: Prompt for chapter generationusers
: Array of user objects belonging to the organization{
"organizations": [
{
"_id": "org123456789",
"activity": true,
"org_manager_view_all": true,
"aviary_export_allowed": true,
"require_session_passwords": false,
"groups": ["group1234", "group5678", "group9012"],
"organization_name": "Community Archives Project",
"organizational_code": "cap_admin_2023",
"created_at": "2023-04-15T14:27:42.519Z",
"__v": 5,
"local_recordings_polyfill": false,
"allow_dial_in": true,
"local_recordings_allowed": true,
"permanent_org": {
"export_allowed": true,
"archive_nbr": "07kp-2341"
},
"credits": 1750000,
"backgroundUrl": "uploads/projectbackgrounds/community-archives-bg.jpg",
"maxProjectsAllowed": 300,
"projects": 187,
"recording_hours": 428,
"branding": true,
"settings": {
"transcription_service": "cloudconvert",
"filler_words": false,
"vocabulary": ["oral history", "archives", "cultural heritage"],
"auto_chaptering": true,
"summary_prompt": "Create a concise summary of this oral history interview focusing on the key topics, historical events, and personal experiences discussed.",
"chaptering_prompt": "Divide this interview into logical chapters based on topic changes and significant moments."
},
"users": [
{
"_id": "user123456",
"is_verified": false,
"role": "admin",
"stories": [],
"full_name": "Emma Johnson",
"email": "emma.johnson@example.com",
"organization": "org123456789",
"signed_up": "2023-05-12T15:32:47.821Z",
"__v": 0,
"create_gallery": true,
"featureFlags": {
"enableTwilioVideo": true,
"localRecordingMimeType": "video/webm;codecs=vp8,opus",
"disableAutomaticResolutionSwitching": false,
"autoChaptering": true,
"_id": "flag123456"
}
}
]
}
]
}
Retrieves information about stories (recordings) with pagination support.
https://node.theirstory.io/stories/
pageSize
(optional): Number of items per page (default: 15)page
(optional): Page number to retrieve (default: 1)https://node.theirstory.io/stories/?pageSize=15&page=1
The response includes pagination information and an array of story objects with comprehensive details about each recording.
page
: Current page numbertotal
: Total number of storiesitems
: Array of story objects, each containing details about the recordingRetrieves the transcript of a specific story in JSON format, including words, timestamps, and other transcript metadata.
https://node.theirstory.io/transcripts/{storyid}
storyid
(required): The unique identifier of the storyThe response is a JSON object containing detailed transcript information, story metadata, and associated media URLs.
transcript
: Object containing transcript details
_id
: Unique identifier for the transcriptcreated_at
: Timestamp when the transcript was createdwords
: Array of word objects, each containing:
start
: Start time of the word in secondsend
: End time of the word in secondstext
: The actual wordparagraphs
: Array of paragraph objects with speaker and timing informationstatus
: Status of the transcript (e.g., "completed")storyId
: ID of the associated storyupdated_at
: Timestamp when the transcript was last updatedstory
: Object containing story details
_id
: Unique identifier for the storytitle
: Title of the storyauthor
: Information about the story's author/creatorrecord_date
: Date when the recording was madeduration
: Duration of the recording in secondsindexes
: Array of index objects containing chapter metadataasyncOperations
: Array of processing operations performed on the storyvideoURL
: URL to access the video recordingparticipants
: Array of participants in the recordingtags
: Array of tags associated with the recording{
"transcript": {
"_id": "abc123def456ghi789",
"created_at": "2025-01-27T16:46:48.850Z",
"words": [
{
"start": 1.12,
"end": 1.44,
"text": "Super"
},
{
"start": 1.44,
"end": 1.8,
"text": "quickly."
},
{
"start": 1.8,
"end": 2.16,
"text": "Then"
},
// Additional words...
],
"paragraphs": [
{
"start": 0,
"end": 105.6,
"speaker": "SPEAKER_S1"
}
],
"status": "completed",
"storyId": "def456ghi789jkl012",
"updated_at": "2025-01-27T16:46:48.850Z"
},
"story": {
"_id": "def456ghi789jkl012",
"title": "Example Recording",
"record_date": "2025-01-27T16:44:51.289Z",
"duration": 107,
// Additional story metadata...
},
"videoURL": "https://example.s3.amazonaws.com/uploads/example-id/transcoded.mp4?token=example",
"participants": [],
"tags": []
}
Retrieves the transcript of a specific story in HTML format, suitable for interactive transcripts using the Hyperaudio Lite library.
https://node.theirstory.io/stories/{storyid}/html
storyid
(required): The unique identifier of the storyThe response is an HTML document containing the transcript with timing data attributes that make it compatible with interactive transcript libraries like Hyperaudio Lite.
<article>
<section>
<p>
<span data-m="0" data-d="0" class="speaker">SPEAKER_S1: </span>
<span data-m="1120" data-d="320">Super </span>
<span data-m="1440" data-d="360">quickly. </span>
<span data-m="1800" data-d="360">Then </span>
<span data-m="2240" data-d="240">this </span>
<span data-m="2480" data-d="200">is </span>
<span data-m="2680" data-d="200">the </span>
<span data-m="3040" data-d="280">bug </span>
<span data-m="3320" data-d="320">where </span>
...
</p>
</section>
</article>
data-m
: Timestamp in milliseconds for when the word beginsdata-d
: Duration of the word in millisecondsclass="speaker"
: Denotes a speaker change in the transcriptThis HTML format is designed to work with libraries like Hyperaudio Lite to create interactive transcripts where:
Retrieves information about groups within an organization.
https://node.theirstory.io/groups
The API uses standard HTTP status codes to indicate success or failure of requests. Error responses include detailed information about the error and possible solutions.
When working with the TheirStory API, keep the following security considerations in mind: