All URIs are relative to http://localhost
| Method | HTTP request | Description |
|---|---|---|
| DeleteService | Delete /rest/api/v1/services/{service} | delete the service with a given name |
| GetService | Get /rest/api/v1/services/{service} | get a single service by name |
| GetServicePromoters | Get /rest/api/v1/services/{service}/promoters | get all users who may promote a service |
| GetServices | Get /rest/api/v1/services | get services |
| PatchService | Patch /rest/api/v1/services/{service} | patch an existing service with the given name |
| RegisterService | Post /rest/api/v1/services/{service} | register a new service with the given name |
| UpdateService | Put /rest/api/v1/services/{service} | update an existing service with the given name |
DeleteService(ctx, service).DeletionDto(deletionDto).Execute()
delete the service with a given name
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/Interhyp/metadata-service-api"
)
func main() {
service := "service_example" // string | The (globally unique) name of the service, must match `^[a-z](-?[a-z0-9]+)*$`.
deletionDto := *openapiclient.NewDeletionDto("JiraIssue_example") // DeletionDto |
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
r, err := apiClient.RestApiV1ServicesAPI.DeleteService(context.Background(), service).DeletionDto(deletionDto).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `RestApiV1ServicesAPI.DeleteService``: %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. | |
| service | string | The (globally unique) name of the service, must match `^a-z*$`. |
Other parameters are passed through a pointer to a apiDeleteServiceRequest struct via the builder pattern
| Name | Type | Description | Notes |
|---|
deletionDto | DeletionDto | |
(empty response body)
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
ServiceDto GetService(ctx, service).Execute()
get a single service by name
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/Interhyp/metadata-service-api"
)
func main() {
service := "service_example" // string | The (globally unique) name of the service, must match `^[a-z](-?[a-z0-9]+)*$`.
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.RestApiV1ServicesAPI.GetService(context.Background(), service).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `RestApiV1ServicesAPI.GetService``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `GetService`: ServiceDto
fmt.Fprintf(os.Stdout, "Response from `RestApiV1ServicesAPI.GetService`: %v\n", resp)
}| Name | Type | Description | Notes |
|---|---|---|---|
| ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
| service | string | The (globally unique) name of the service, must match `^a-z*$`. |
Other parameters are passed through a pointer to a apiGetServiceRequest struct via the builder pattern
| Name | Type | Description | Notes |
|---|
No authorization required
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
ServicePromotersDto GetServicePromoters(ctx, service).Execute()
get all users who may promote a service
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/Interhyp/metadata-service-api"
)
func main() {
service := "service_example" // string | The (globally unique) name of the service, must match `^[a-z](-?[a-z0-9]+)*$`.
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.RestApiV1ServicesAPI.GetServicePromoters(context.Background(), service).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `RestApiV1ServicesAPI.GetServicePromoters``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `GetServicePromoters`: ServicePromotersDto
fmt.Fprintf(os.Stdout, "Response from `RestApiV1ServicesAPI.GetServicePromoters`: %v\n", resp)
}| Name | Type | Description | Notes |
|---|---|---|---|
| ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
| service | string | The (globally unique) name of the service, must match `^a-z*$`. |
Other parameters are passed through a pointer to a apiGetServicePromotersRequest struct via the builder pattern
| Name | Type | Description | Notes |
|---|
No authorization required
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
ServiceListDto GetServices(ctx).Owner(owner).Execute()
get services
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/Interhyp/metadata-service-api"
)
func main() {
owner := "some-owner" // string | Allows filtering the output by owner alias. Valid aliases match `^[a-z](-?[a-z0-9]+)*$`. (optional)
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.RestApiV1ServicesAPI.GetServices(context.Background()).Owner(owner).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `RestApiV1ServicesAPI.GetServices``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `GetServices`: ServiceListDto
fmt.Fprintf(os.Stdout, "Response from `RestApiV1ServicesAPI.GetServices`: %v\n", resp)
}Other parameters are passed through a pointer to a apiGetServicesRequest struct via the builder pattern
| Name | Type | Description | Notes |
|---|---|---|---|
| owner | string | Allows filtering the output by owner alias. Valid aliases match `^a-z*$`. |
No authorization required
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
ServiceDto PatchService(ctx, service).ServicePatchDto(servicePatchDto).Execute()
patch an existing service with the given name
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/Interhyp/metadata-service-api"
)
func main() {
service := "service_example" // string | The (globally unique) name of the service, must match `^[a-z](-?[a-z0-9]+)*$`.
servicePatchDto := *openapiclient.NewServicePatchDto("TimeStamp_example", "CommitHash_example", "JiraIssue_example") // ServicePatchDto |
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.RestApiV1ServicesAPI.PatchService(context.Background(), service).ServicePatchDto(servicePatchDto).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `RestApiV1ServicesAPI.PatchService``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `PatchService`: ServiceDto
fmt.Fprintf(os.Stdout, "Response from `RestApiV1ServicesAPI.PatchService`: %v\n", resp)
}| Name | Type | Description | Notes |
|---|---|---|---|
| ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
| service | string | The (globally unique) name of the service, must match `^a-z*$`. |
Other parameters are passed through a pointer to a apiPatchServiceRequest struct via the builder pattern
| Name | Type | Description | Notes |
|---|
servicePatchDto | ServicePatchDto | |
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
ServiceDto RegisterService(ctx, service).ServiceCreateDto(serviceCreateDto).Execute()
register a new service with the given name
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/Interhyp/metadata-service-api"
)
func main() {
service := "service_example" // string | The (globally unique) name of the service, must match `^[a-z](-?[a-z0-9]+)*$`.
serviceCreateDto := *openapiclient.NewServiceCreateDto("Owner_example", []openapiclient.Quicklink{*openapiclient.NewQuicklink()}, []string{"Repositories_example"}, "AlertTarget_example", "JiraIssue_example") // ServiceCreateDto |
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.RestApiV1ServicesAPI.RegisterService(context.Background(), service).ServiceCreateDto(serviceCreateDto).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `RestApiV1ServicesAPI.RegisterService``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `RegisterService`: ServiceDto
fmt.Fprintf(os.Stdout, "Response from `RestApiV1ServicesAPI.RegisterService`: %v\n", resp)
}| Name | Type | Description | Notes |
|---|---|---|---|
| ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
| service | string | The (globally unique) name of the service, must match `^a-z*$`. |
Other parameters are passed through a pointer to a apiRegisterServiceRequest struct via the builder pattern
| Name | Type | Description | Notes |
|---|
serviceCreateDto | ServiceCreateDto | |
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
ServiceDto UpdateService(ctx, service).ServiceDto(serviceDto).Execute()
update an existing service with the given name
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/Interhyp/metadata-service-api"
)
func main() {
service := "service_example" // string | The (globally unique) name of the service, must match `^[a-z](-?[a-z0-9]+)*$`.
serviceDto := *openapiclient.NewServiceDto("Owner_example", []openapiclient.Quicklink{*openapiclient.NewQuicklink()}, []string{"Repositories_example"}, "AlertTarget_example", "TimeStamp_example", "CommitHash_example", "JiraIssue_example") // ServiceDto |
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.RestApiV1ServicesAPI.UpdateService(context.Background(), service).ServiceDto(serviceDto).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `RestApiV1ServicesAPI.UpdateService``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `UpdateService`: ServiceDto
fmt.Fprintf(os.Stdout, "Response from `RestApiV1ServicesAPI.UpdateService`: %v\n", resp)
}| Name | Type | Description | Notes |
|---|---|---|---|
| ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
| service | string | The (globally unique) name of the service, must match `^a-z*$`. |
Other parameters are passed through a pointer to a apiUpdateServiceRequest struct via the builder pattern
| Name | Type | Description | Notes |
|---|
serviceDto | ServiceDto | |
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]