All URIs are relative to https://api.phrase.com/v2
| Method | HTTP request | Description |
|---|---|---|
| job_annotation_delete | DELETE /projects/{project_id}/jobs/{job_id}/annotations/{id} | Delete a job annotation |
| job_annotation_update | PATCH /projects/{project_id}/jobs/{job_id}/annotations/{id} | Create/Update a job annotation |
| job_annotations_list | GET /projects/{project_id}/jobs/{job_id}/annotations | List job annotations |
| job_locale_annotation_delete | DELETE /projects/{project_id}/jobs/{job_id}/locales/{job_locale_id}/annotations/{id} | Delete a job locale annotation |
| job_locale_annotation_update | PATCH /projects/{project_id}/jobs/{job_id}/locales/{job_locale_id}/annotations/{id} | Create/Update a job locale annotation |
| job_locale_annotations_list | GET /projects/{project_id}/jobs/{job_id}/locales/{job_locale_id}/annotations | List job locale annotations |
job_annotation_delete(project_id, job_id, id, x_phrase_app_otp=x_phrase_app_otp, branch=branch)
Delete a job annotation
Delete an annotation for a job.
from __future__ import print_function
import time
import phrase_api
from phrase_api.rest import ApiException
from pprint import pprint
configuration = phrase_api.Configuration()
configuration.api_key['Authorization'] = 'YOUR_API_KEY'
configuration.api_key_prefix['Authorization'] = 'token'
# Enter a context with an instance of the API client
with phrase_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = phrase_api.JobAnnotationsApi(api_client)
project_id = 'project_id_example' # str | Project ID (required)
job_id = 'job_id_example' # str | Job ID (required)
id = 'id_example' # str | Name of the annotation to delete. (required)
x_phrase_app_otp = 'x_phrase_app_otp_example' # str | Two-Factor-Authentication token (optional)
branch = 'my-feature-branch' # str | Branch to use
try:
# Delete a job annotation
api_instance.job_annotation_delete(project_id, job_id, id, x_phrase_app_otp=x_phrase_app_otp, branch=branch)
except ApiException as e:
print("Exception when calling JobAnnotationsApi->job_annotation_delete: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| project_id | str | Project ID | |
| job_id | str | Job ID | |
| id | str | Name of the annotation to delete. | |
| x_phrase_app_otp | str | Two-Factor-Authentication token (optional) | [optional] |
| branch | str | Branch to use | [optional] |
void (empty response body)
- Content-Type: Not defined
- Accept: Not defined
| Status code | Description | Response headers |
|---|---|---|
| 204 | No Content | * X-Rate-Limit-Limit - * X-Rate-Limit-Remaining - * X-Rate-Limit-Reset - |
| 400 | Bad request. The request could not be parsed or a parameter failed validation. Verify the request body, the content type, and the parameter types, then retry. | * X-Rate-Limit-Limit - * X-Rate-Limit-Remaining - * X-Rate-Limit-Reset - |
| 404 | Not found. The requested resource does not exist or is not visible to the authenticated user. Verify the identifiers in the request path and that the token has access to them, then retry. | * X-Rate-Limit-Limit - * X-Rate-Limit-Remaining - * X-Rate-Limit-Reset - |
| 429 | Too many requests. The rate limit has been exceeded. Wait until the time indicated by the `X-Rate-Limit-Reset` response header before retrying. | * X-Rate-Limit-Limit - * X-Rate-Limit-Remaining - * X-Rate-Limit-Reset - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
JobAnnotation job_annotation_update(project_id, job_id, id, job_annotation_update_parameters, x_phrase_app_otp=x_phrase_app_otp)
Create/Update a job annotation
Create or update an annotation for a job. If the annotation already exists, it will be updated; otherwise, a new annotation will be created.
from __future__ import print_function
import time
import phrase_api
from phrase_api.rest import ApiException
from pprint import pprint
configuration = phrase_api.Configuration()
configuration.api_key['Authorization'] = 'YOUR_API_KEY'
configuration.api_key_prefix['Authorization'] = 'token'
# Enter a context with an instance of the API client
with phrase_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = phrase_api.JobAnnotationsApi(api_client)
project_id = 'project_id_example' # str | Project ID (required)
job_id = 'job_id_example' # str | Job ID (required)
id = 'id_example' # str | Name of the annotation to set or update. (required)
job_annotation_update_parameters = phrase_api.JobAnnotationUpdateParameters() # JobAnnotationUpdateParameters | (required)
x_phrase_app_otp = 'x_phrase_app_otp_example' # str | Two-Factor-Authentication token (optional)
try:
# Create/Update a job annotation
api_response = api_instance.job_annotation_update(project_id, job_id, id, job_annotation_update_parameters, x_phrase_app_otp=x_phrase_app_otp)
pprint(api_response)
except ApiException as e:
print("Exception when calling JobAnnotationsApi->job_annotation_update: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| project_id | str | Project ID | |
| job_id | str | Job ID | |
| id | str | Name of the annotation to set or update. | |
| job_annotation_update_parameters | JobAnnotationUpdateParameters | ||
| x_phrase_app_otp | str | Two-Factor-Authentication token (optional) | [optional] |
- Content-Type: application/json
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | OK | * X-Rate-Limit-Limit - * X-Rate-Limit-Remaining - * X-Rate-Limit-Reset - |
| 400 | Bad request. The request could not be parsed or a parameter failed validation. Verify the request body, the content type, and the parameter types, then retry. | * X-Rate-Limit-Limit - * X-Rate-Limit-Remaining - * X-Rate-Limit-Reset - |
| 404 | Not found. The requested resource does not exist or is not visible to the authenticated user. Verify the identifiers in the request path and that the token has access to them, then retry. | * X-Rate-Limit-Limit - * X-Rate-Limit-Remaining - * X-Rate-Limit-Reset - |
| 429 | Too many requests. The rate limit has been exceeded. Wait until the time indicated by the `X-Rate-Limit-Reset` response header before retrying. | * X-Rate-Limit-Limit - * X-Rate-Limit-Remaining - * X-Rate-Limit-Reset - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
List[JobAnnotation] job_annotations_list(project_id, job_id, x_phrase_app_otp=x_phrase_app_otp, branch=branch)
List job annotations
Retrieve a list of annotations for a job.
from __future__ import print_function
import time
import phrase_api
from phrase_api.rest import ApiException
from pprint import pprint
configuration = phrase_api.Configuration()
configuration.api_key['Authorization'] = 'YOUR_API_KEY'
configuration.api_key_prefix['Authorization'] = 'token'
# Enter a context with an instance of the API client
with phrase_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = phrase_api.JobAnnotationsApi(api_client)
project_id = 'project_id_example' # str | Project ID (required)
job_id = 'job_id_example' # str | Job ID (required)
x_phrase_app_otp = 'x_phrase_app_otp_example' # str | Two-Factor-Authentication token (optional)
branch = 'my-feature-branch' # str | Branch to use
try:
# List job annotations
api_response = api_instance.job_annotations_list(project_id, job_id, x_phrase_app_otp=x_phrase_app_otp, branch=branch)
pprint(api_response)
except ApiException as e:
print("Exception when calling JobAnnotationsApi->job_annotations_list: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| project_id | str | Project ID | |
| job_id | str | Job ID | |
| x_phrase_app_otp | str | Two-Factor-Authentication token (optional) | [optional] |
| branch | str | Branch to use | [optional] |
- Content-Type: Not defined
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | OK | * X-Rate-Limit-Limit - * X-Rate-Limit-Remaining - * X-Rate-Limit-Reset - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
job_locale_annotation_delete(project_id, job_id, job_locale_id, id, x_phrase_app_otp=x_phrase_app_otp, branch=branch)
Delete a job locale annotation
Delete an annotation for a job locale.
from __future__ import print_function
import time
import phrase_api
from phrase_api.rest import ApiException
from pprint import pprint
configuration = phrase_api.Configuration()
configuration.api_key['Authorization'] = 'YOUR_API_KEY'
configuration.api_key_prefix['Authorization'] = 'token'
# Enter a context with an instance of the API client
with phrase_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = phrase_api.JobAnnotationsApi(api_client)
project_id = 'project_id_example' # str | Project ID (required)
job_id = 'job_id_example' # str | Job ID (required)
job_locale_id = 'job_locale_id_example' # str | Job Locale ID (required)
id = 'id_example' # str | Name of the annotation to delete. (required)
x_phrase_app_otp = 'x_phrase_app_otp_example' # str | Two-Factor-Authentication token (optional)
branch = 'my-feature-branch' # str | Branch to use
try:
# Delete a job locale annotation
api_instance.job_locale_annotation_delete(project_id, job_id, job_locale_id, id, x_phrase_app_otp=x_phrase_app_otp, branch=branch)
except ApiException as e:
print("Exception when calling JobAnnotationsApi->job_locale_annotation_delete: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| project_id | str | Project ID | |
| job_id | str | Job ID | |
| job_locale_id | str | Job Locale ID | |
| id | str | Name of the annotation to delete. | |
| x_phrase_app_otp | str | Two-Factor-Authentication token (optional) | [optional] |
| branch | str | Branch to use | [optional] |
void (empty response body)
- Content-Type: Not defined
- Accept: Not defined
| Status code | Description | Response headers |
|---|---|---|
| 204 | No Content | * X-Rate-Limit-Limit - * X-Rate-Limit-Remaining - * X-Rate-Limit-Reset - |
| 400 | Bad request. The request could not be parsed or a parameter failed validation. Verify the request body, the content type, and the parameter types, then retry. | * X-Rate-Limit-Limit - * X-Rate-Limit-Remaining - * X-Rate-Limit-Reset - |
| 404 | Not found. The requested resource does not exist or is not visible to the authenticated user. Verify the identifiers in the request path and that the token has access to them, then retry. | * X-Rate-Limit-Limit - * X-Rate-Limit-Remaining - * X-Rate-Limit-Reset - |
| 429 | Too many requests. The rate limit has been exceeded. Wait until the time indicated by the `X-Rate-Limit-Reset` response header before retrying. | * X-Rate-Limit-Limit - * X-Rate-Limit-Remaining - * X-Rate-Limit-Reset - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
JobAnnotation job_locale_annotation_update(project_id, job_id, job_locale_id, id, job_annotation_update_parameters, x_phrase_app_otp=x_phrase_app_otp)
Create/Update a job locale annotation
Create or update an annotation for a job locale. If the annotation already exists, it will be updated; otherwise, a new annotation will be created.
from __future__ import print_function
import time
import phrase_api
from phrase_api.rest import ApiException
from pprint import pprint
configuration = phrase_api.Configuration()
configuration.api_key['Authorization'] = 'YOUR_API_KEY'
configuration.api_key_prefix['Authorization'] = 'token'
# Enter a context with an instance of the API client
with phrase_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = phrase_api.JobAnnotationsApi(api_client)
project_id = 'project_id_example' # str | Project ID (required)
job_id = 'job_id_example' # str | Job ID (required)
job_locale_id = 'job_locale_id_example' # str | Job Locale ID (required)
id = 'id_example' # str | Name of the annotation to set or update. (required)
job_annotation_update_parameters = phrase_api.JobAnnotationUpdateParameters() # JobAnnotationUpdateParameters | (required)
x_phrase_app_otp = 'x_phrase_app_otp_example' # str | Two-Factor-Authentication token (optional)
try:
# Create/Update a job locale annotation
api_response = api_instance.job_locale_annotation_update(project_id, job_id, job_locale_id, id, job_annotation_update_parameters, x_phrase_app_otp=x_phrase_app_otp)
pprint(api_response)
except ApiException as e:
print("Exception when calling JobAnnotationsApi->job_locale_annotation_update: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| project_id | str | Project ID | |
| job_id | str | Job ID | |
| job_locale_id | str | Job Locale ID | |
| id | str | Name of the annotation to set or update. | |
| job_annotation_update_parameters | JobAnnotationUpdateParameters | ||
| x_phrase_app_otp | str | Two-Factor-Authentication token (optional) | [optional] |
- Content-Type: application/json
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | OK | * X-Rate-Limit-Limit - * X-Rate-Limit-Remaining - * X-Rate-Limit-Reset - |
| 400 | Bad request. The request could not be parsed or a parameter failed validation. Verify the request body, the content type, and the parameter types, then retry. | * X-Rate-Limit-Limit - * X-Rate-Limit-Remaining - * X-Rate-Limit-Reset - |
| 404 | Not found. The requested resource does not exist or is not visible to the authenticated user. Verify the identifiers in the request path and that the token has access to them, then retry. | * X-Rate-Limit-Limit - * X-Rate-Limit-Remaining - * X-Rate-Limit-Reset - |
| 429 | Too many requests. The rate limit has been exceeded. Wait until the time indicated by the `X-Rate-Limit-Reset` response header before retrying. | * X-Rate-Limit-Limit - * X-Rate-Limit-Remaining - * X-Rate-Limit-Reset - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
List[JobAnnotation] job_locale_annotations_list(project_id, job_id, job_locale_id, x_phrase_app_otp=x_phrase_app_otp, branch=branch)
List job locale annotations
Retrieve a list of annotations for a job locale.
from __future__ import print_function
import time
import phrase_api
from phrase_api.rest import ApiException
from pprint import pprint
configuration = phrase_api.Configuration()
configuration.api_key['Authorization'] = 'YOUR_API_KEY'
configuration.api_key_prefix['Authorization'] = 'token'
# Enter a context with an instance of the API client
with phrase_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = phrase_api.JobAnnotationsApi(api_client)
project_id = 'project_id_example' # str | Project ID (required)
job_id = 'job_id_example' # str | Job ID (required)
job_locale_id = 'job_locale_id_example' # str | Job Locale ID (required)
x_phrase_app_otp = 'x_phrase_app_otp_example' # str | Two-Factor-Authentication token (optional)
branch = 'my-feature-branch' # str | Branch to use
try:
# List job locale annotations
api_response = api_instance.job_locale_annotations_list(project_id, job_id, job_locale_id, x_phrase_app_otp=x_phrase_app_otp, branch=branch)
pprint(api_response)
except ApiException as e:
print("Exception when calling JobAnnotationsApi->job_locale_annotations_list: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| project_id | str | Project ID | |
| job_id | str | Job ID | |
| job_locale_id | str | Job Locale ID | |
| x_phrase_app_otp | str | Two-Factor-Authentication token (optional) | [optional] |
| branch | str | Branch to use | [optional] |
- Content-Type: Not defined
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | OK | * X-Rate-Limit-Limit - * X-Rate-Limit-Remaining - * X-Rate-Limit-Reset - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]