Link Search Menu Expand Document

Prevail API: Edit Sessions

Edit Sessions (Self-Service)

PATCH https://prevail.ai/api/v1/sessions/[:remote_session_id]

Edit a Session created by your Organization. The Session must belong to your Organization and be in a state of scheduled or ready. Your Organization must have Self-Service enabled to use this request to edit scheduled Sessions. Only Prevail Staff can enable Self-Service for your Organization.

  • To update any of start_date, start_time, or time_zone, all three options must be included.

Query Parameters

remote_session_id string required
The unique identifier for the Session you want to edit.
  • Use the GET Sessions endpoint to retrieve a list of Sessions and their remote_session_id values.

Authorization

Bearer Token {{jwt_signed}}

Used to authenticate the request. Replace with your access token.

Headers

Content-Type application/json

Specifies the format of the request body.

Accept application/json

Specifies the expected format of the response body.

Example Request

cURL
curl -X PATCH "https://prevail.ai/api/v1/sessions/example-remote-session-id" \
  -H "Authorization: Bearer YOUR_ACCESS_TOKEN" \
  -H "Content-Type: application/json" \
  -H "Accept: application/json" \
  -d '{
   "remote_session": {
        "title": "Example Remote Session Edited",
        "start_time": "02:30 PM",
        "start_date": "2025-01-30",
        "time_zone": "Pacific Time (US & Canada)",
        "invites": ["amethyst@example.com"]
    }
}'
        
JavaScript
// Update session using fetch API
const updateData = {
  remote_session: {
    title: "Example Remote Session Edited",
    start_time: "02:30 PM",
    start_date: "2025-01-30",
    time_zone: "Pacific Time (US & Canada)",
    invites: ["amethyst@example.com"]
  }
};

async function updateSession() {
  const response = await fetch('https://prevail.ai/api/v1/sessions/example-remote-session-id', {
    method: 'PATCH',
    headers: {
      'Authorization': 'Bearer YOUR_ACCESS_TOKEN',
      'Content-Type': 'application/json',
      'Accept': 'application/json'
    },
    body: JSON.stringify(updateData)
  });

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

// Call the function
updateSession();
        
Python
import requests
import json

url = "https://prevail.ai/api/v1/sessions/example-remote-session-id"

headers = {
    "Authorization": "Bearer YOUR_ACCESS_TOKEN",
    "Content-Type": "application/json",
    "Accept": "application/json"
}

update_data = {
    "remote_session": {
        "title": "Example Remote Session Edited",
        "start_time": "02:30 PM",
        "start_date": "2025-01-30",
        "time_zone": "Pacific Time (US & Canada)",
        "invites": ["amethyst@example.com"]
    }
}

response = requests.patch(url, headers=headers, data=json.dumps(update_data))
data = response.json()
print(data)
        
HTTP
PATCH https://prevail.ai/api/v1/sessions/example-remote-session-id
Authorization: Bearer YOUR_ACCESS_TOKEN
Content-Type: application/json
Accept: application/json

{
   "remote_session": {
        "title": "Example Remote Session Edited",
        "start_time": "02:30 PM",
        "start_date": "2025-01-30",
        "time_zone": "Pacific Time (US & Canada)",
        "invites": ["amethyst@example.com"]
    }
}
        

Example Response

The sessions array in the API response returns objects representing each Session. In an update operation, the remote_session_id remains unchanged to ensure the Session URL stays constant. The title, start_date, and start_time fields are updated to their new values, and state is assigned the value ready. Added participants appear in the invites array.

{
    "sessions": [
        {
            "remote_session_id": "example-remote-session-id", 
            "title": "Example Remote Session Edited",  
            "start_date": "2025-01-30", 
            "start_time": "02:30 PM", 
            "time_zone": "Pacific Time (US & Canada)", 
            "state": "ready",
            "estimated_duration": 3.5,
            "transcript_status": "in_progress",
            "invites": [
                "quartz@example.com",
                "obsidian@example.com",
                "amethyst@example.com" 
            ],
            "provider_specific_details": { 
                "meeting_id": 97969731904,
                "password": "ysitdagyst",
                "provider_join_url": "https://zoom.us/j/97969731904?pwd=MhujrdD4UXWIeubEbPJhDbhKs1VT0P.1",
                "prevail_join_url": "https://staging.prevail.ai/sessions/example-remote-session/zoom_meeting"
            }
        }
    ]
}
        

Copyright ©2025 Prevail Legal

Last modified: May 22, 2025