Skip to content

Reports API

All URIs are relative to https://api.syntheticusers.com/api/v1

MethodHTTP requestDescription
create_reportPOST /reportsCreate Report
delete_reportDELETE /reports/Delete Report
generate_full_reportPOST /reports/{report_id}/generateGenerate Full Report
generate_toc_endpointPOST /reports/{report_id}/generate-tocGenerate Toc Endpoint
get_reportGET /reports/Get Report
get_report_pdfGET /reports/{report_id}/pdfGet Report Pdf
list_reportsGET /reportsList Reports
update_reportPATCH /reports/Update Report

create_report

StandaloneReport create_report(standalone_report_create)

Create Report

Create a new standalone report from studies and automatically start TOC generation.

Example

  • Bearer Authentication (HTTPBearer):
python
import syntheticusers
from syntheticusers.models.standalone_report import StandaloneReport
from syntheticusers.models.standalone_report_create import StandaloneReportCreate
from syntheticusers.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to https://api.syntheticusers.com/api/v1
# See configuration.py for a list of all supported configuration parameters.
configuration = syntheticusers.Configuration(
    host = "https://api.syntheticusers.com/api/v1"
)

# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.

# Configure Bearer authorization: HTTPBearer
configuration = syntheticusers.Configuration(
    access_token = os.environ["BEARER_TOKEN"]
)

# Enter a context with an instance of the API client
with syntheticusers.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = syntheticusers.ReportsApi(api_client)
    standalone_report_create = syntheticusers.StandaloneReportCreate() # StandaloneReportCreate | 

    try:
        # Create Report
        api_response = api_instance.create_report(standalone_report_create)
        print("The response of ReportsApi->create_report:\n")
        pprint(api_response)
    except Exception as e:
        print("Exception when calling ReportsApi->create_report: %s\n" % e)

Parameters

NameTypeDescriptionNotes
standalone_report_createStandaloneReportCreate

Return type

StandaloneReport

Authorization

HTTPBearer

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

HTTP response details

Status codeDescriptionResponse headers
200Successful Response-
422Validation Error-

[Back to top] [Back to API list] [Back to SDK]

delete_report

delete_report(report_id)

Delete Report

Delete a standalone report.

Example

  • Bearer Authentication (HTTPBearer):
python
import syntheticusers
from syntheticusers.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to https://api.syntheticusers.com/api/v1
# See configuration.py for a list of all supported configuration parameters.
configuration = syntheticusers.Configuration(
    host = "https://api.syntheticusers.com/api/v1"
)

# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.

# Configure Bearer authorization: HTTPBearer
configuration = syntheticusers.Configuration(
    access_token = os.environ["BEARER_TOKEN"]
)

# Enter a context with an instance of the API client
with syntheticusers.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = syntheticusers.ReportsApi(api_client)
    report_id = 'report_id_example' # str | 

    try:
        # Delete Report
        api_instance.delete_report(report_id)
    except Exception as e:
        print("Exception when calling ReportsApi->delete_report: %s\n" % e)

Parameters

NameTypeDescriptionNotes
report_idstr

Return type

void (empty response body)

Authorization

HTTPBearer

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

HTTP response details

Status codeDescriptionResponse headers
204Successful Response-
422Validation Error-

[Back to top] [Back to API list] [Back to SDK]

generate_full_report

StandaloneReport generate_full_report(report_id)

Generate Full Report

Start full report generation (requires TOC to be present).

Example

  • Bearer Authentication (HTTPBearer):
python
import syntheticusers
from syntheticusers.models.standalone_report import StandaloneReport
from syntheticusers.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to https://api.syntheticusers.com/api/v1
# See configuration.py for a list of all supported configuration parameters.
configuration = syntheticusers.Configuration(
    host = "https://api.syntheticusers.com/api/v1"
)

# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.

# Configure Bearer authorization: HTTPBearer
configuration = syntheticusers.Configuration(
    access_token = os.environ["BEARER_TOKEN"]
)

# Enter a context with an instance of the API client
with syntheticusers.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = syntheticusers.ReportsApi(api_client)
    report_id = 'report_id_example' # str | 

    try:
        # Generate Full Report
        api_response = api_instance.generate_full_report(report_id)
        print("The response of ReportsApi->generate_full_report:\n")
        pprint(api_response)
    except Exception as e:
        print("Exception when calling ReportsApi->generate_full_report: %s\n" % e)

Parameters

NameTypeDescriptionNotes
report_idstr

Return type

StandaloneReport

Authorization

HTTPBearer

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

HTTP response details

Status codeDescriptionResponse headers
200Successful Response-
422Validation Error-

[Back to top] [Back to API list] [Back to SDK]

generate_toc_endpoint

StandaloneReport generate_toc_endpoint(report_id, generate_toc_request=generate_toc_request)

Generate Toc Endpoint

Generate table of contents for a standalone report using LLM (async).

Args: report_id: The ID of the report request_body: Optional request body with focus parameter

Example

  • Bearer Authentication (HTTPBearer):
python
import syntheticusers
from syntheticusers.models.generate_toc_request import GenerateTOCRequest
from syntheticusers.models.standalone_report import StandaloneReport
from syntheticusers.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to https://api.syntheticusers.com/api/v1
# See configuration.py for a list of all supported configuration parameters.
configuration = syntheticusers.Configuration(
    host = "https://api.syntheticusers.com/api/v1"
)

# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.

# Configure Bearer authorization: HTTPBearer
configuration = syntheticusers.Configuration(
    access_token = os.environ["BEARER_TOKEN"]
)

# Enter a context with an instance of the API client
with syntheticusers.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = syntheticusers.ReportsApi(api_client)
    report_id = 'report_id_example' # str | 
    generate_toc_request = syntheticusers.GenerateTOCRequest() # GenerateTOCRequest |  (optional)

    try:
        # Generate Toc Endpoint
        api_response = api_instance.generate_toc_endpoint(report_id, generate_toc_request=generate_toc_request)
        print("The response of ReportsApi->generate_toc_endpoint:\n")
        pprint(api_response)
    except Exception as e:
        print("Exception when calling ReportsApi->generate_toc_endpoint: %s\n" % e)

Parameters

NameTypeDescriptionNotes
report_idstr
generate_toc_requestGenerateTOCRequest[optional]

Return type

StandaloneReport

Authorization

HTTPBearer

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

HTTP response details

Status codeDescriptionResponse headers
200Successful Response-
422Validation Error-

[Back to top] [Back to API list] [Back to SDK]

get_report

StandaloneReport get_report(report_id)

Get Report

Get a specific standalone report.

Example

  • Bearer Authentication (HTTPBearer):
python
import syntheticusers
from syntheticusers.models.standalone_report import StandaloneReport
from syntheticusers.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to https://api.syntheticusers.com/api/v1
# See configuration.py for a list of all supported configuration parameters.
configuration = syntheticusers.Configuration(
    host = "https://api.syntheticusers.com/api/v1"
)

# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.

# Configure Bearer authorization: HTTPBearer
configuration = syntheticusers.Configuration(
    access_token = os.environ["BEARER_TOKEN"]
)

# Enter a context with an instance of the API client
with syntheticusers.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = syntheticusers.ReportsApi(api_client)
    report_id = 'report_id_example' # str | 

    try:
        # Get Report
        api_response = api_instance.get_report(report_id)
        print("The response of ReportsApi->get_report:\n")
        pprint(api_response)
    except Exception as e:
        print("Exception when calling ReportsApi->get_report: %s\n" % e)

Parameters

NameTypeDescriptionNotes
report_idstr

Return type

StandaloneReport

Authorization

HTTPBearer

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

HTTP response details

Status codeDescriptionResponse headers
200Successful Response-
422Validation Error-

[Back to top] [Back to API list] [Back to SDK]

get_report_pdf

bytearray get_report_pdf(report_id)

Get Report Pdf

Download standalone report as PDF.

Example

  • Bearer Authentication (HTTPBearer):
python
import syntheticusers
from syntheticusers.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to https://api.syntheticusers.com/api/v1
# See configuration.py for a list of all supported configuration parameters.
configuration = syntheticusers.Configuration(
    host = "https://api.syntheticusers.com/api/v1"
)

# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.

# Configure Bearer authorization: HTTPBearer
configuration = syntheticusers.Configuration(
    access_token = os.environ["BEARER_TOKEN"]
)

# Enter a context with an instance of the API client
with syntheticusers.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = syntheticusers.ReportsApi(api_client)
    report_id = 'report_id_example' # str | 

    try:
        # Get Report Pdf
        api_response = api_instance.get_report_pdf(report_id)
        print("The response of ReportsApi->get_report_pdf:\n")
        pprint(api_response)
    except Exception as e:
        print("Exception when calling ReportsApi->get_report_pdf: %s\n" % e)

Parameters

NameTypeDescriptionNotes
report_idstr

Return type

bytearray

Authorization

HTTPBearer

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/pdf, application/json

HTTP response details

Status codeDescriptionResponse headers
200Returns the PDF report-
404Report not found-
500Error generating report-
422Validation Error-

[Back to top] [Back to API list] [Back to SDK]

list_reports

PageStandaloneReport list_reports(project_id=project_id, report_type=report_type, status=status, page=page, size=size)

List Reports

List standalone reports (report_mode='standalone' only).

Example

  • Bearer Authentication (HTTPBearer):
python
import syntheticusers
from syntheticusers.models.page_standalone_report import PageStandaloneReport
from syntheticusers.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to https://api.syntheticusers.com/api/v1
# See configuration.py for a list of all supported configuration parameters.
configuration = syntheticusers.Configuration(
    host = "https://api.syntheticusers.com/api/v1"
)

# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.

# Configure Bearer authorization: HTTPBearer
configuration = syntheticusers.Configuration(
    access_token = os.environ["BEARER_TOKEN"]
)

# Enter a context with an instance of the API client
with syntheticusers.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = syntheticusers.ReportsApi(api_client)
    project_id = 'project_id_example' # str | Project ID filter (optional)
    report_type = 'report_type_example' # str | Report type: standard or multiconcept (optional)
    status = 'status_example' # str | Status filter (optional)
    page = 1 # int | Page number (optional) (default to 1)
    size = 50 # int | Page size (optional) (default to 50)

    try:
        # List Reports
        api_response = api_instance.list_reports(project_id=project_id, report_type=report_type, status=status, page=page, size=size)
        print("The response of ReportsApi->list_reports:\n")
        pprint(api_response)
    except Exception as e:
        print("Exception when calling ReportsApi->list_reports: %s\n" % e)

Parameters

NameTypeDescriptionNotes
project_idstrProject ID filter[optional]
report_typestrReport type: standard or multiconcept[optional]
statusstrStatus filter[optional]
pageintPage number[optional] [default to 1]
sizeintPage size[optional] [default to 50]

Return type

PageStandaloneReport

Authorization

HTTPBearer

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

HTTP response details

Status codeDescriptionResponse headers
200Successful Response-
422Validation Error-

[Back to top] [Back to API list] [Back to SDK]

update_report

StandaloneReport update_report(report_id, standalone_report_update=standalone_report_update)

Update Report

Update a standalone report (e.g., table_of_contents, focus).

Example

  • Bearer Authentication (HTTPBearer):
python
import syntheticusers
from syntheticusers.models.standalone_report import StandaloneReport
from syntheticusers.models.standalone_report_update import StandaloneReportUpdate
from syntheticusers.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to https://api.syntheticusers.com/api/v1
# See configuration.py for a list of all supported configuration parameters.
configuration = syntheticusers.Configuration(
    host = "https://api.syntheticusers.com/api/v1"
)

# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.

# Configure Bearer authorization: HTTPBearer
configuration = syntheticusers.Configuration(
    access_token = os.environ["BEARER_TOKEN"]
)

# Enter a context with an instance of the API client
with syntheticusers.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = syntheticusers.ReportsApi(api_client)
    report_id = 'report_id_example' # str | 
    standalone_report_update = syntheticusers.StandaloneReportUpdate() # StandaloneReportUpdate |  (optional)

    try:
        # Update Report
        api_response = api_instance.update_report(report_id, standalone_report_update=standalone_report_update)
        print("The response of ReportsApi->update_report:\n")
        pprint(api_response)
    except Exception as e:
        print("Exception when calling ReportsApi->update_report: %s\n" % e)

Parameters

NameTypeDescriptionNotes
report_idstr
standalone_report_updateStandaloneReportUpdate[optional]

Return type

StandaloneReport

Authorization

HTTPBearer

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

HTTP response details

Status codeDescriptionResponse headers
200Successful Response-
422Validation Error-

[Back to top] [Back to API list] [Back to SDK]

Released under the MIT License.