Skip to content

Latest commit

 

History

History
423 lines (280 loc) · 13.2 KB

QualityProfileApi.md

File metadata and controls

423 lines (280 loc) · 13.2 KB

sonarr.QualityProfileApi

All URIs are relative to http://localhost:8989

Method HTTP request Description
create_quality_profile POST /api/v3/qualityprofile
delete_quality_profile DELETE /api/v3/qualityprofile/{id}
get_quality_profile_by_id GET /api/v3/qualityprofile/{id}
list_quality_profile GET /api/v3/qualityprofile
update_quality_profile PUT /api/v3/qualityprofile/{id}

create_quality_profile

QualityProfileResource create_quality_profile(quality_profile_resource=quality_profile_resource)

Example

  • Api Key Authentication (apikey):
  • Api Key Authentication (X-Api-Key):
import sonarr
from sonarr.models.quality_profile_resource import QualityProfileResource
from sonarr.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to http://localhost:8989
# See configuration.py for a list of all supported configuration parameters.
configuration = sonarr.Configuration(
    host = "http://localhost:8989"
)

# 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 API key authorization: apikey
configuration.api_key['apikey'] = os.environ["API_KEY"]

# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['apikey'] = 'Bearer'

# Configure API key authorization: X-Api-Key
configuration.api_key['X-Api-Key'] = os.environ["API_KEY"]

# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['X-Api-Key'] = 'Bearer'

# Enter a context with an instance of the API client
with sonarr.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = sonarr.QualityProfileApi(api_client)
    quality_profile_resource = sonarr.QualityProfileResource() # QualityProfileResource |  (optional)

    try:
        api_response = api_instance.create_quality_profile(quality_profile_resource=quality_profile_resource)
        print("The response of QualityProfileApi->create_quality_profile:\n")
        pprint(api_response)
    except Exception as e:
        print("Exception when calling QualityProfileApi->create_quality_profile: %s\n" % e)

Parameters

Name Type Description Notes
quality_profile_resource QualityProfileResource [optional]

Return type

QualityProfileResource

Authorization

apikey, X-Api-Key

HTTP request headers

  • Content-Type: application/json
  • Accept: text/plain, application/json, text/json

HTTP response details

Status code Description Response headers
2XX OK -

[Back to top] [Back to API list] [Back to Model list] [Back to README]

delete_quality_profile

delete_quality_profile(id)

Example

  • Api Key Authentication (apikey):
  • Api Key Authentication (X-Api-Key):
import sonarr
from sonarr.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to http://localhost:8989
# See configuration.py for a list of all supported configuration parameters.
configuration = sonarr.Configuration(
    host = "http://localhost:8989"
)

# 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 API key authorization: apikey
configuration.api_key['apikey'] = os.environ["API_KEY"]

# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['apikey'] = 'Bearer'

# Configure API key authorization: X-Api-Key
configuration.api_key['X-Api-Key'] = os.environ["API_KEY"]

# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['X-Api-Key'] = 'Bearer'

# Enter a context with an instance of the API client
with sonarr.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = sonarr.QualityProfileApi(api_client)
    id = 56 # int | 

    try:
        api_instance.delete_quality_profile(id)
    except Exception as e:
        print("Exception when calling QualityProfileApi->delete_quality_profile: %s\n" % e)

Parameters

Name Type Description Notes
id int

Return type

void (empty response body)

Authorization

apikey, X-Api-Key

HTTP request headers

  • Content-Type: Not defined
  • Accept: Not defined

HTTP response details

Status code Description Response headers
2XX OK -

[Back to top] [Back to API list] [Back to Model list] [Back to README]

get_quality_profile_by_id

QualityProfileResource get_quality_profile_by_id(id)

Example

  • Api Key Authentication (apikey):
  • Api Key Authentication (X-Api-Key):
import sonarr
from sonarr.models.quality_profile_resource import QualityProfileResource
from sonarr.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to http://localhost:8989
# See configuration.py for a list of all supported configuration parameters.
configuration = sonarr.Configuration(
    host = "http://localhost:8989"
)

# 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 API key authorization: apikey
configuration.api_key['apikey'] = os.environ["API_KEY"]

# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['apikey'] = 'Bearer'

# Configure API key authorization: X-Api-Key
configuration.api_key['X-Api-Key'] = os.environ["API_KEY"]

# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['X-Api-Key'] = 'Bearer'

# Enter a context with an instance of the API client
with sonarr.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = sonarr.QualityProfileApi(api_client)
    id = 56 # int | 

    try:
        api_response = api_instance.get_quality_profile_by_id(id)
        print("The response of QualityProfileApi->get_quality_profile_by_id:\n")
        pprint(api_response)
    except Exception as e:
        print("Exception when calling QualityProfileApi->get_quality_profile_by_id: %s\n" % e)

Parameters

Name Type Description Notes
id int

Return type

QualityProfileResource

Authorization

apikey, X-Api-Key

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

HTTP response details

Status code Description Response headers
2XX OK -

[Back to top] [Back to API list] [Back to Model list] [Back to README]

list_quality_profile

List[QualityProfileResource] list_quality_profile()

Example

  • Api Key Authentication (apikey):
  • Api Key Authentication (X-Api-Key):
import sonarr
from sonarr.models.quality_profile_resource import QualityProfileResource
from sonarr.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to http://localhost:8989
# See configuration.py for a list of all supported configuration parameters.
configuration = sonarr.Configuration(
    host = "http://localhost:8989"
)

# 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 API key authorization: apikey
configuration.api_key['apikey'] = os.environ["API_KEY"]

# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['apikey'] = 'Bearer'

# Configure API key authorization: X-Api-Key
configuration.api_key['X-Api-Key'] = os.environ["API_KEY"]

# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['X-Api-Key'] = 'Bearer'

# Enter a context with an instance of the API client
with sonarr.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = sonarr.QualityProfileApi(api_client)

    try:
        api_response = api_instance.list_quality_profile()
        print("The response of QualityProfileApi->list_quality_profile:\n")
        pprint(api_response)
    except Exception as e:
        print("Exception when calling QualityProfileApi->list_quality_profile: %s\n" % e)

Parameters

This endpoint does not need any parameter.

Return type

List[QualityProfileResource]

Authorization

apikey, X-Api-Key

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

HTTP response details

Status code Description Response headers
2XX OK -

[Back to top] [Back to API list] [Back to Model list] [Back to README]

update_quality_profile

QualityProfileResource update_quality_profile(id, quality_profile_resource=quality_profile_resource)

Example

  • Api Key Authentication (apikey):
  • Api Key Authentication (X-Api-Key):
import sonarr
from sonarr.models.quality_profile_resource import QualityProfileResource
from sonarr.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to http://localhost:8989
# See configuration.py for a list of all supported configuration parameters.
configuration = sonarr.Configuration(
    host = "http://localhost:8989"
)

# 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 API key authorization: apikey
configuration.api_key['apikey'] = os.environ["API_KEY"]

# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['apikey'] = 'Bearer'

# Configure API key authorization: X-Api-Key
configuration.api_key['X-Api-Key'] = os.environ["API_KEY"]

# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['X-Api-Key'] = 'Bearer'

# Enter a context with an instance of the API client
with sonarr.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = sonarr.QualityProfileApi(api_client)
    id = 'id_example' # str | 
    quality_profile_resource = sonarr.QualityProfileResource() # QualityProfileResource |  (optional)

    try:
        api_response = api_instance.update_quality_profile(id, quality_profile_resource=quality_profile_resource)
        print("The response of QualityProfileApi->update_quality_profile:\n")
        pprint(api_response)
    except Exception as e:
        print("Exception when calling QualityProfileApi->update_quality_profile: %s\n" % e)

Parameters

Name Type Description Notes
id str
quality_profile_resource QualityProfileResource [optional]

Return type

QualityProfileResource

Authorization

apikey, X-Api-Key

HTTP request headers

  • Content-Type: application/json
  • Accept: text/plain, application/json, text/json

HTTP response details

Status code Description Response headers
2XX OK -

[Back to top] [Back to API list] [Back to Model list] [Back to README]