All URIs are relative to http://localhost:8989
Method | HTTP request | Description |
---|---|---|
CreateQualityProfile | Post /api/v3/qualityprofile | |
DeleteQualityProfile | Delete /api/v3/qualityprofile/{id} | |
GetQualityProfileById | Get /api/v3/qualityprofile/{id} | |
ListQualityProfile | Get /api/v3/qualityprofile | |
UpdateQualityProfile | Put /api/v3/qualityprofile/{id} |
QualityProfileResource CreateQualityProfile(ctx).QualityProfileResource(qualityProfileResource).Execute()
package main
import (
"context"
"fmt"
"os"
sonarrClient "github.com/devopsarr/sonarr-go/sonarr"
)
func main() {
qualityProfileResource := *sonarrClient.NewQualityProfileResource() // QualityProfileResource | (optional)
configuration := sonarrClient.NewConfiguration()
apiClient := sonarrClient.NewAPIClient(configuration)
resp, r, err := apiClient.QualityProfileAPI.CreateQualityProfile(context.Background()).QualityProfileResource(qualityProfileResource).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `QualityProfileAPI.CreateQualityProfile``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `CreateQualityProfile`: QualityProfileResource
fmt.Fprintf(os.Stdout, "Response from `QualityProfileAPI.CreateQualityProfile`: %v\n", resp)
}
Other parameters are passed through a pointer to a apiCreateQualityProfileRequest struct via the builder pattern
Name | Type | Description | Notes |
---|---|---|---|
qualityProfileResource | QualityProfileResource |
- Content-Type: application/json
- Accept: text/plain, application/json, text/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
DeleteQualityProfile(ctx, id).Execute()
package main
import (
"context"
"fmt"
"os"
sonarrClient "github.com/devopsarr/sonarr-go/sonarr"
)
func main() {
id := int32(56) // int32 |
configuration := sonarrClient.NewConfiguration()
apiClient := sonarrClient.NewAPIClient(configuration)
r, err := apiClient.QualityProfileAPI.DeleteQualityProfile(context.Background(), id).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `QualityProfileAPI.DeleteQualityProfile``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
id | int32 |
Other parameters are passed through a pointer to a apiDeleteQualityProfileRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
(empty response body)
- Content-Type: Not defined
- Accept: Not defined
[Back to top] [Back to API list] [Back to Model list] [Back to README]
QualityProfileResource GetQualityProfileById(ctx, id).Execute()
package main
import (
"context"
"fmt"
"os"
sonarrClient "github.com/devopsarr/sonarr-go/sonarr"
)
func main() {
id := int32(56) // int32 |
configuration := sonarrClient.NewConfiguration()
apiClient := sonarrClient.NewAPIClient(configuration)
resp, r, err := apiClient.QualityProfileAPI.GetQualityProfileById(context.Background(), id).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `QualityProfileAPI.GetQualityProfileById``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `GetQualityProfileById`: QualityProfileResource
fmt.Fprintf(os.Stdout, "Response from `QualityProfileAPI.GetQualityProfileById`: %v\n", resp)
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
id | int32 |
Other parameters are passed through a pointer to a apiGetQualityProfileByIdRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
[]QualityProfileResource ListQualityProfile(ctx).Execute()
package main
import (
"context"
"fmt"
"os"
sonarrClient "github.com/devopsarr/sonarr-go/sonarr"
)
func main() {
configuration := sonarrClient.NewConfiguration()
apiClient := sonarrClient.NewAPIClient(configuration)
resp, r, err := apiClient.QualityProfileAPI.ListQualityProfile(context.Background()).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `QualityProfileAPI.ListQualityProfile``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `ListQualityProfile`: []QualityProfileResource
fmt.Fprintf(os.Stdout, "Response from `QualityProfileAPI.ListQualityProfile`: %v\n", resp)
}
This endpoint does not need any parameter.
Other parameters are passed through a pointer to a apiListQualityProfileRequest struct via the builder pattern
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
QualityProfileResource UpdateQualityProfile(ctx, id).QualityProfileResource(qualityProfileResource).Execute()
package main
import (
"context"
"fmt"
"os"
sonarrClient "github.com/devopsarr/sonarr-go/sonarr"
)
func main() {
id := "id_example" // string |
qualityProfileResource := *sonarrClient.NewQualityProfileResource() // QualityProfileResource | (optional)
configuration := sonarrClient.NewConfiguration()
apiClient := sonarrClient.NewAPIClient(configuration)
resp, r, err := apiClient.QualityProfileAPI.UpdateQualityProfile(context.Background(), id).QualityProfileResource(qualityProfileResource).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `QualityProfileAPI.UpdateQualityProfile``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `UpdateQualityProfile`: QualityProfileResource
fmt.Fprintf(os.Stdout, "Response from `QualityProfileAPI.UpdateQualityProfile`: %v\n", resp)
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
id | string |
Other parameters are passed through a pointer to a apiUpdateQualityProfileRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
qualityProfileResource | QualityProfileResource | |
- Content-Type: application/json
- Accept: text/plain, application/json, text/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]