All URIs are relative to http://localhost:8989
Method | HTTP request | Description |
---|---|---|
CreateRemotePathMapping | Post /api/v3/remotepathmapping | |
DeleteRemotePathMapping | Delete /api/v3/remotepathmapping/{id} | |
GetRemotePathMappingById | Get /api/v3/remotepathmapping/{id} | |
ListRemotePathMapping | Get /api/v3/remotepathmapping | |
UpdateRemotePathMapping | Put /api/v3/remotepathmapping/{id} |
RemotePathMappingResource CreateRemotePathMapping(ctx).RemotePathMappingResource(remotePathMappingResource).Execute()
package main
import (
"context"
"fmt"
"os"
sonarrClient "github.com/devopsarr/sonarr-go/sonarr"
)
func main() {
remotePathMappingResource := *sonarrClient.NewRemotePathMappingResource() // RemotePathMappingResource | (optional)
configuration := sonarrClient.NewConfiguration()
apiClient := sonarrClient.NewAPIClient(configuration)
resp, r, err := apiClient.RemotePathMappingAPI.CreateRemotePathMapping(context.Background()).RemotePathMappingResource(remotePathMappingResource).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `RemotePathMappingAPI.CreateRemotePathMapping``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `CreateRemotePathMapping`: RemotePathMappingResource
fmt.Fprintf(os.Stdout, "Response from `RemotePathMappingAPI.CreateRemotePathMapping`: %v\n", resp)
}
Other parameters are passed through a pointer to a apiCreateRemotePathMappingRequest struct via the builder pattern
Name | Type | Description | Notes |
---|---|---|---|
remotePathMappingResource | RemotePathMappingResource |
- 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]
DeleteRemotePathMapping(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.RemotePathMappingAPI.DeleteRemotePathMapping(context.Background(), id).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `RemotePathMappingAPI.DeleteRemotePathMapping``: %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 apiDeleteRemotePathMappingRequest 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]
RemotePathMappingResource GetRemotePathMappingById(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.RemotePathMappingAPI.GetRemotePathMappingById(context.Background(), id).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `RemotePathMappingAPI.GetRemotePathMappingById``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `GetRemotePathMappingById`: RemotePathMappingResource
fmt.Fprintf(os.Stdout, "Response from `RemotePathMappingAPI.GetRemotePathMappingById`: %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 apiGetRemotePathMappingByIdRequest 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]
[]RemotePathMappingResource ListRemotePathMapping(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.RemotePathMappingAPI.ListRemotePathMapping(context.Background()).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `RemotePathMappingAPI.ListRemotePathMapping``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `ListRemotePathMapping`: []RemotePathMappingResource
fmt.Fprintf(os.Stdout, "Response from `RemotePathMappingAPI.ListRemotePathMapping`: %v\n", resp)
}
This endpoint does not need any parameter.
Other parameters are passed through a pointer to a apiListRemotePathMappingRequest 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]
RemotePathMappingResource UpdateRemotePathMapping(ctx, id).RemotePathMappingResource(remotePathMappingResource).Execute()
package main
import (
"context"
"fmt"
"os"
sonarrClient "github.com/devopsarr/sonarr-go/sonarr"
)
func main() {
id := "id_example" // string |
remotePathMappingResource := *sonarrClient.NewRemotePathMappingResource() // RemotePathMappingResource | (optional)
configuration := sonarrClient.NewConfiguration()
apiClient := sonarrClient.NewAPIClient(configuration)
resp, r, err := apiClient.RemotePathMappingAPI.UpdateRemotePathMapping(context.Background(), id).RemotePathMappingResource(remotePathMappingResource).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `RemotePathMappingAPI.UpdateRemotePathMapping``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `UpdateRemotePathMapping`: RemotePathMappingResource
fmt.Fprintf(os.Stdout, "Response from `RemotePathMappingAPI.UpdateRemotePathMapping`: %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 apiUpdateRemotePathMappingRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
remotePathMappingResource | RemotePathMappingResource | |
- Content-Type: application/json, text/json, application/*+json
- Accept: text/plain, application/json, text/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]