Appearance
Interviews API
All URIs are relative to https://api.syntheticusers.com/api/v1
| Method | HTTP request | Description |
|---|---|---|
| get_interview | GET /interviews/ | Get Interview |
| interview_follow_up | POST /interviews/{interview_id}/follow_up | Interview Follow Up |
| list_interviews | GET /interviews | List Interviews |
| regenerate_interview | POST /interviews/{interview_id}/regenerate | Regenerate Interview |
get_interview
Interview get_interview(interview_id)
Get Interview
Example
- Bearer Authentication (HTTPBearer):
python
import syntheticusers
from syntheticusers.models.interview import Interview
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.InterviewsApi(api_client)
interview_id = 'interview_id_example' # str |
try:
# Get Interview
api_response = api_instance.get_interview(interview_id)
print("The response of InterviewsApi->get_interview:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling InterviewsApi->get_interview: %s\n" % e)Parameters
| Name | Type | Description | Notes |
|---|---|---|---|
| interview_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]
interview_follow_up
Conversation interview_follow_up(interview_id, conversation_create)
Interview Follow Up
Example
- Bearer Authentication (HTTPBearer):
python
import syntheticusers
from syntheticusers.models.conversation import Conversation
from syntheticusers.models.conversation_create import ConversationCreate
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.InterviewsApi(api_client)
interview_id = 'interview_id_example' # str |
conversation_create = syntheticusers.ConversationCreate() # ConversationCreate |
try:
# Interview Follow Up
api_response = api_instance.interview_follow_up(interview_id, conversation_create)
print("The response of InterviewsApi->interview_follow_up:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling InterviewsApi->interview_follow_up: %s\n" % e)Parameters
| Name | Type | Description | Notes |
|---|---|---|---|
| interview_id | str | ||
| conversation_create | ConversationCreate |
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]
list_interviews
PageInterview list_interviews(id=id, project_id=project_id, audience_id=audience_id, study_id=study_id, synthetic_user_id=synthetic_user_id, status=status, page=page, size=size)
List Interviews
Example
- Bearer Authentication (HTTPBearer):
python
import syntheticusers
from syntheticusers.models.page_interview import PageInterview
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.InterviewsApi(api_client)
id = 'id_example' # str | Comma-separated list of interviews IDs (optional)
project_id = 'project_id_example' # str | Comma-separated list of project IDs (optional)
audience_id = 'audience_id_example' # str | Comma-separated list of audiences IDs (optional)
study_id = 'study_id_example' # str | Comma-separated list of studies IDs (optional)
synthetic_user_id = 'synthetic_user_id_example' # str | Comma-separated list of synthetic users IDs (optional)
status = 'status_example' # str | Status to filter by (optional)
page = 1 # int | Page number (optional) (default to 1)
size = 50 # int | Page size (optional) (default to 50)
try:
# List Interviews
api_response = api_instance.list_interviews(id=id, project_id=project_id, audience_id=audience_id, study_id=study_id, synthetic_user_id=synthetic_user_id, status=status, page=page, size=size)
print("The response of InterviewsApi->list_interviews:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling InterviewsApi->list_interviews: %s\n" % e)Parameters
| Name | Type | Description | Notes |
|---|---|---|---|
| id | str | Comma-separated list of interviews IDs | [optional] |
| project_id | str | Comma-separated list of project IDs | [optional] |
| audience_id | str | Comma-separated list of audiences IDs | [optional] |
| study_id | str | Comma-separated list of studies IDs | [optional] |
| synthetic_user_id | str | Comma-separated list of synthetic users IDs | [optional] |
| status | str | Status to filter by | [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]
regenerate_interview
Interview regenerate_interview(interview_id)
Regenerate Interview
Example
- Bearer Authentication (HTTPBearer):
python
import syntheticusers
from syntheticusers.models.interview import Interview
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.InterviewsApi(api_client)
interview_id = 'interview_id_example' # str |
try:
# Regenerate Interview
api_response = api_instance.regenerate_interview(interview_id)
print("The response of InterviewsApi->regenerate_interview:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling InterviewsApi->regenerate_interview: %s\n" % e)Parameters
| Name | Type | Description | Notes |
|---|---|---|---|
| interview_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 | - |