Appearance
Reports API
All URIs are relative to https://api.syntheticusers.com/api/v1
| Method | HTTP request | Description |
|---|---|---|
| create_report | POST /reports | Create Report |
| delete_report | DELETE /reports/ | Delete Report |
| generate_full_report | POST /reports/{report_id}/generate | Generate Full Report |
| generate_toc_endpoint | POST /reports/{report_id}/generate-toc | Generate Toc Endpoint |
| get_report | GET /reports/ | Get Report |
| get_report_pdf | GET /reports/{report_id}/pdf | Get Report Pdf |
| list_reports | GET /reports | List Reports |
| update_report | PATCH /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
| Name | Type | Description | Notes |
|---|---|---|---|
| standalone_report_create | StandaloneReportCreate |
Return type
Authorization
HTTP request headers
- Content-Type: application/json
- Accept: application/json
HTTP response details
| Status code | Description | Response headers |
|---|---|---|
| 200 | Successful Response | - |
| 422 | Validation 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
| Name | Type | Description | Notes |
|---|---|---|---|
| report_id | str |
Return type
void (empty response body)
Authorization
HTTP request headers
- Content-Type: Not defined
- Accept: application/json
HTTP response details
| Status code | Description | Response headers |
|---|---|---|
| 204 | Successful Response | - |
| 422 | Validation 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
| Name | Type | Description | Notes |
|---|---|---|---|
| report_id | str |
Return type
Authorization
HTTP request headers
- Content-Type: Not defined
- Accept: application/json
HTTP response details
| Status code | Description | Response headers |
|---|---|---|
| 200 | Successful Response | - |
| 422 | Validation 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
| Name | Type | Description | Notes |
|---|---|---|---|
| report_id | str | ||
| generate_toc_request | GenerateTOCRequest | [optional] |
Return type
Authorization
HTTP request headers
- Content-Type: application/json
- Accept: application/json
HTTP response details
| Status code | Description | Response headers |
|---|---|---|
| 200 | Successful Response | - |
| 422 | Validation 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
| Name | Type | Description | Notes |
|---|---|---|---|
| report_id | str |
Return type
Authorization
HTTP request headers
- Content-Type: Not defined
- Accept: application/json
HTTP response details
| Status code | Description | Response headers |
|---|---|---|
| 200 | Successful Response | - |
| 422 | Validation 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
| Name | Type | Description | Notes |
|---|---|---|---|
| report_id | str |
Return type
bytearray
Authorization
HTTP request headers
- Content-Type: Not defined
- Accept: application/pdf, application/json
HTTP response details
| Status code | Description | Response headers |
|---|---|---|
| 200 | Returns the PDF report | - |
| 404 | Report not found | - |
| 500 | Error generating report | - |
| 422 | Validation 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
| Name | Type | Description | Notes |
|---|---|---|---|
| project_id | str | Project ID filter | [optional] |
| report_type | str | Report type: standard or multiconcept | [optional] |
| status | str | Status filter | [optional] |
| page | int | Page number | [optional] [default to 1] |
| size | int | Page size | [optional] [default to 50] |
Return type
Authorization
HTTP request headers
- Content-Type: Not defined
- Accept: application/json
HTTP response details
| Status code | Description | Response headers |
|---|---|---|
| 200 | Successful Response | - |
| 422 | Validation 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
| Name | Type | Description | Notes |
|---|---|---|---|
| report_id | str | ||
| standalone_report_update | StandaloneReportUpdate | [optional] |
Return type
Authorization
HTTP request headers
- Content-Type: application/json
- Accept: application/json
HTTP response details
| Status code | Description | Response headers |
|---|---|---|
| 200 | Successful Response | - |
| 422 | Validation Error | - |