Batch Approve Sections
POST
/api/canvas/{deal_id}/sections/batch-approve
const url = 'https://example.com/api/canvas/example/sections/batch-approve';const options = {method: 'POST', headers: {Authorization: 'Bearer <token>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://example.com/api/canvas/example/sections/batch-approve \ --header 'Authorization: Bearer <token>'Approve all sections currently in ‘reviewed’ state.
This is a convenience endpoint for one-click approval of all reviewed sections, typically invoked from the FinalizeBar’s “Approve All” button.
Args: deal_id: Deal identifier request: FastAPI request (used for broadcast helpers) user: Authenticated user from JWT canvas_service: Canvas service instance
Returns: BatchApproveResponse with per-section results
Raises: HTTPException: 403 if user doesn’t have access to deal
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”deal_id
required
Deal Id
string
Responses
Section titled “Responses”Successful Response
Media typeapplication/json
BatchApproveResponse
Response for batch approve operation.
object
Examplegenerated
{ "results": [ { "section_key": "example", "success": true, "error": "example" } ], "all_success": true, "approved_count": 1}Validation Error
Media typeapplication/json
HTTPValidationError
object
detail
Detail
Array<object>
ValidationErrorobject
loc
required
Location
Array
msg
required
Message
string
type
required
Error Type
string
input
Input
ctx
Context
object
Examplegenerated
{ "detail": [ { "loc": [ "example" ], "msg": "example", "type": "example", "input": "example", "ctx": {} } ]}