Skip to content

Solutions API

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

MethodHTTP requestDescription
create_solutionPOST /solutionsCreate Solution
delete_solutionDELETE /solutions/Delete Solution
edit_solutionPATCH /solutions/Edit Solution
get_solutionGET /solutions/Get Solution
list_solutionsGET /solutionsList Solutions

create_solution

Solution create_solution(solution_create)

Create Solution

Example

  • Bearer Authentication (HTTPBearer):
python
import syntheticusers
from syntheticusers.models.solution import Solution
from syntheticusers.models.solution_create import SolutionCreate
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.SolutionsApi(api_client)
    solution_create = syntheticusers.SolutionCreate() # SolutionCreate | 

    try:
        # Create Solution
        api_response = api_instance.create_solution(solution_create)
        print("The response of SolutionsApi->create_solution:\n")
        pprint(api_response)
    except Exception as e:
        print("Exception when calling SolutionsApi->create_solution: %s\n" % e)

Parameters

NameTypeDescriptionNotes
solution_createSolutionCreate

Return type

Solution

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_solution

object delete_solution(solution_id)

Delete Solution

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.SolutionsApi(api_client)
    solution_id = 'solution_id_example' # str | 

    try:
        # Delete Solution
        api_response = api_instance.delete_solution(solution_id)
        print("The response of SolutionsApi->delete_solution:\n")
        pprint(api_response)
    except Exception as e:
        print("Exception when calling SolutionsApi->delete_solution: %s\n" % e)

Parameters

NameTypeDescriptionNotes
solution_idstr

Return type

object

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]

edit_solution

Solution edit_solution(solution_id, solution_update)

Edit Solution

Example

  • Bearer Authentication (HTTPBearer):
python
import syntheticusers
from syntheticusers.models.solution import Solution
from syntheticusers.models.solution_update import SolutionUpdate
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.SolutionsApi(api_client)
    solution_id = 'solution_id_example' # str | 
    solution_update = syntheticusers.SolutionUpdate() # SolutionUpdate | 

    try:
        # Edit Solution
        api_response = api_instance.edit_solution(solution_id, solution_update)
        print("The response of SolutionsApi->edit_solution:\n")
        pprint(api_response)
    except Exception as e:
        print("Exception when calling SolutionsApi->edit_solution: %s\n" % e)

Parameters

NameTypeDescriptionNotes
solution_idstr
solution_updateSolutionUpdate

Return type

Solution

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_solution

Solution get_solution(solution_id)

Get Solution

Example

  • Bearer Authentication (HTTPBearer):
python
import syntheticusers
from syntheticusers.models.solution import Solution
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.SolutionsApi(api_client)
    solution_id = 'solution_id_example' # str | 

    try:
        # Get Solution
        api_response = api_instance.get_solution(solution_id)
        print("The response of SolutionsApi->get_solution:\n")
        pprint(api_response)
    except Exception as e:
        print("Exception when calling SolutionsApi->get_solution: %s\n" % e)

Parameters

NameTypeDescriptionNotes
solution_idstr

Return type

Solution

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]

list_solutions

PageSolution list_solutions(page=page, size=size)

List Solutions

Example

  • Bearer Authentication (HTTPBearer):
python
import syntheticusers
from syntheticusers.models.page_solution import PageSolution
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.SolutionsApi(api_client)
    page = 1 # int | Page number (optional) (default to 1)
    size = 50 # int | Page size (optional) (default to 50)

    try:
        # List Solutions
        api_response = api_instance.list_solutions(page=page, size=size)
        print("The response of SolutionsApi->list_solutions:\n")
        pprint(api_response)
    except Exception as e:
        print("Exception when calling SolutionsApi->list_solutions: %s\n" % e)

Parameters

NameTypeDescriptionNotes
pageintPage number[optional] [default to 1]
sizeintPage size[optional] [default to 50]

Return type

PageSolution

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]

Released under the MIT License.