All URIs are relative to https://ws.api.video
Method | HTTP request | Description |
---|---|---|
upload | POST /watermarks | Upload a watermark |
delete | DELETE /watermarks/{watermarkId} | Delete a watermark |
list | GET /watermarks | List all watermarks |
Watermark upload(file)
Upload a watermark
Create a new watermark by uploading a JPG
or a PNG
image.
import apivideo
from apivideo.api import watermarks_api
from apivideo.model.too_many_requests import TooManyRequests
from apivideo.model.bad_request import BadRequest
from apivideo.model.watermark import Watermark
from pprint import pprint
# Enter a context with an instance of the API client
with apivideo.AuthenticatedApiClient(__API_KEY__) as api_client:
# Create an instance of the API class
api_instance = watermarks_api.WatermarksApi(api_client)
file = open('/path/to/file', 'rb') # file_type | The `.jpg` or `.png` image to be added as a watermark.
# example passing only required values which don't have defaults set
try:
# Upload a watermark
api_response = api_instance.upload(file)
pprint(api_response)
except apivideo.ApiException as e:
print("Exception when calling WatermarksApi->upload: %s\n" % e)
Name | Type | Description | Notes |
---|---|---|---|
file | file_type | The `.jpg` or `.png` image to be added as a watermark. |
- Content-Type: multipart/form-data
- Accept: application/json
Status code | Description | Response headers |
---|---|---|
200 | Success | * X-RateLimit-Limit - The request limit per minute. * X-RateLimit-Remaining - The number of available requests left for the current time window. * X-RateLimit-Retry-After - The number of seconds left until the current rate limit window resets. |
400 | Bad Request | * X-RateLimit-Limit - The request limit per minute. * X-RateLimit-Remaining - The number of available requests left for the current time window. * X-RateLimit-Retry-After - The number of seconds left until the current rate limit window resets. |
429 | Too Many Requests | * X-RateLimit-Limit - The request limit per minute. * X-RateLimit-Remaining - The number of available requests left for the current time window. * X-RateLimit-Retry-After - The number of seconds left until the current rate limit window resets. |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
delete(watermark_id)
Delete a watermark
Delete a watermark.
import apivideo
from apivideo.api import watermarks_api
from apivideo.model.too_many_requests import TooManyRequests
from apivideo.model.not_found import NotFound
from pprint import pprint
# Enter a context with an instance of the API client
with apivideo.AuthenticatedApiClient(__API_KEY__) as api_client:
# Create an instance of the API class
api_instance = watermarks_api.WatermarksApi(api_client)
watermark_id = "watermark_1BWr2L5MTQwxGkuxKjzh6i" # str | The watermark ID for the watermark you want to delete.
# example passing only required values which don't have defaults set
try:
# Delete a watermark
api_instance.delete(watermark_id)
except apivideo.ApiException as e:
print("Exception when calling WatermarksApi->delete: %s\n" % e)
Name | Type | Description | Notes |
---|---|---|---|
watermark_id | str | The watermark ID for the watermark you want to delete. |
void (empty response body)
- Content-Type: Not defined
- Accept: application/json
Status code | Description | Response headers |
---|---|---|
204 | No Content | * X-RateLimit-Limit - The request limit per minute. * X-RateLimit-Remaining - The number of available requests left for the current time window. * X-RateLimit-Retry-After - The number of seconds left until the current rate limit window resets. |
404 | Not Found | * X-RateLimit-Limit - The request limit per minute. * X-RateLimit-Remaining - The number of available requests left for the current time window. * X-RateLimit-Retry-After - The number of seconds left until the current rate limit window resets. |
429 | Too Many Requests | * X-RateLimit-Limit - The request limit per minute. * X-RateLimit-Remaining - The number of available requests left for the current time window. * X-RateLimit-Retry-After - The number of seconds left until the current rate limit window resets. |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
WatermarksListResponse list()
List all watermarks
List all watermarks associated with your workspace.
import apivideo
from apivideo.api import watermarks_api
from apivideo.model.too_many_requests import TooManyRequests
from apivideo.model.bad_request import BadRequest
from apivideo.model.watermarks_list_response import WatermarksListResponse
from pprint import pprint
# Enter a context with an instance of the API client
with apivideo.AuthenticatedApiClient(__API_KEY__) as api_client:
# Create an instance of the API class
api_instance = watermarks_api.WatermarksApi(api_client)
sort_by = "createdAt" # str | Allowed: createdAt. You can search by the time watermark were created at. (optional)
sort_order = "asc" # str | Allowed: asc, desc. asc is ascending and sorts from A to Z. desc is descending and sorts from Z to A. (optional)
current_page = 2 # int | Choose the number of search results to return per page. Minimum value: 1 (optional) if omitted the server will use the default value of 1
page_size = 30 # int | Results per page. Allowed values 1-100, default is 25. (optional) if omitted the server will use the default value of 25
# example passing only required values which don't have defaults set
# and optional values
try:
# List all watermarks
api_response = api_instance.list(sort_by=sort_by, sort_order=sort_order, current_page=current_page, page_size=page_size)
pprint(api_response)
except apivideo.ApiException as e:
print("Exception when calling WatermarksApi->list: %s\n" % e)
Name | Type | Description | Notes |
---|---|---|---|
sort_by | str | Allowed: createdAt. You can search by the time watermark were created at. | [optional] |
sort_order | str | Allowed: asc, desc. asc is ascending and sorts from A to Z. desc is descending and sorts from Z to A. | [optional] |
current_page | int | Choose the number of search results to return per page. Minimum value: 1 | [optional] if omitted the server will use the default value of 1 |
page_size | int | Results per page. Allowed values 1-100, default is 25. | [optional] if omitted the server will use the default value of 25 |
- Content-Type: Not defined
- Accept: application/json
Status code | Description | Response headers |
---|---|---|
200 | Success | * X-RateLimit-Limit - The request limit per minute. * X-RateLimit-Remaining - The number of available requests left for the current time window. * X-RateLimit-Retry-After - The number of seconds left until the current rate limit window resets. |
400 | Bad Request | * X-RateLimit-Limit - The request limit per minute. * X-RateLimit-Remaining - The number of available requests left for the current time window. * X-RateLimit-Retry-After - The number of seconds left until the current rate limit window resets. |
429 | Too Many Requests | * X-RateLimit-Limit - The request limit per minute. * X-RateLimit-Remaining - The number of available requests left for the current time window. * X-RateLimit-Retry-After - The number of seconds left until the current rate limit window resets. |
[Back to top] [Back to API list] [Back to Model list] [Back to README]