All URIs are relative to http://localhost
Method | HTTP request | Description |
---|---|---|
BatchAssignTemplate | Post /template/api/v8/templates/{id}/assignments/add | Assigns a template to one or more tenants. |
BatchUnassignTemplate | Post /template/api/v8/templates/{id}/assignments/remove | Unassigns a template from one or more tenants. |
GetAssignment | Get /template/api/v8/templates/assignments/{id} | Gets a template assignment. |
GetAssignmentHistory | Get /template/api/v8/templates/assignments/{id}/history | Gets a template assignment history. |
GetTemplateAssignmentsPage | Get /template/api/v8/templates/assignments | Returns a page of template assignments. |
UpdateAssignmentStatus | Patch /template/api/v8/templates/assignments/{id} | Updates a template assignment status. |
[]TemplateAssignmentResponse BatchAssignTemplate(ctx, id).RequestBody(requestBody).Inheritable(inheritable).Execute()
Assigns a template to one or more tenants.
package main
import (
"context"
"fmt"
"os"
openapiclient "./openapi"
)
func main() {
id := "38400000-8cf0-11bd-b23e-10b96e4ef00d" // string |
requestBody := []string{"Property_example"} // []string |
inheritable := true // bool | (optional)
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.TemplateAssignmentsApi.BatchAssignTemplate(context.Background(), id).RequestBody(requestBody).Inheritable(inheritable).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `TemplateAssignmentsApi.BatchAssignTemplate``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `BatchAssignTemplate`: []TemplateAssignmentResponse
fmt.Fprintf(os.Stdout, "Response from `TemplateAssignmentsApi.BatchAssignTemplate`: %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 apiBatchAssignTemplateRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
requestBody | []string | | inheritable | bool | |
No authorization required
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
[]TemplateAssignmentResponse BatchUnassignTemplate(ctx, id).RequestBody(requestBody).Execute()
Unassigns a template from one or more tenants.
package main
import (
"context"
"fmt"
"os"
openapiclient "./openapi"
)
func main() {
id := "38400000-8cf0-11bd-b23e-10b96e4ef00d" // string |
requestBody := []string{"Property_example"} // []string |
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.TemplateAssignmentsApi.BatchUnassignTemplate(context.Background(), id).RequestBody(requestBody).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `TemplateAssignmentsApi.BatchUnassignTemplate``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `BatchUnassignTemplate`: []TemplateAssignmentResponse
fmt.Fprintf(os.Stdout, "Response from `TemplateAssignmentsApi.BatchUnassignTemplate`: %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 apiBatchUnassignTemplateRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
requestBody | []string | |
No authorization required
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
TemplateAssignment GetAssignment(ctx, id).Execute()
Gets a template assignment.
package main
import (
"context"
"fmt"
"os"
openapiclient "./openapi"
)
func main() {
id := "38400000-8cf0-11bd-b23e-10b96e4ef00d" // string | ID of template assignment record.
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.TemplateAssignmentsApi.GetAssignment(context.Background(), id).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `TemplateAssignmentsApi.GetAssignment``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `GetAssignment`: TemplateAssignment
fmt.Fprintf(os.Stdout, "Response from `TemplateAssignmentsApi.GetAssignment`: %v\n", resp)
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
id | string | ID of template assignment record. |
Other parameters are passed through a pointer to a apiGetAssignmentRequest 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]
[]TemplateAssignment GetAssignmentHistory(ctx, id).Execute()
Gets a template assignment history.
package main
import (
"context"
"fmt"
"os"
openapiclient "./openapi"
)
func main() {
id := "38400000-8cf0-11bd-b23e-10b96e4ef00d" // string |
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.TemplateAssignmentsApi.GetAssignmentHistory(context.Background(), id).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `TemplateAssignmentsApi.GetAssignmentHistory``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `GetAssignmentHistory`: []TemplateAssignment
fmt.Fprintf(os.Stdout, "Response from `TemplateAssignmentsApi.GetAssignmentHistory`: %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 apiGetAssignmentHistoryRequest 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]
TemplateAssignmentsPage GetTemplateAssignmentsPage(ctx).Page(page).PageSize(pageSize).TemplateId(templateId).TenantId(tenantId).CalculateTotalItems(calculateTotalItems).Execute()
Returns a page of template assignments.
package main
import (
"context"
"fmt"
"os"
openapiclient "./openapi"
)
func main() {
page := int32(0) // int32 |
pageSize := int32(10) // int32 |
templateId := "38400000-8cf0-11bd-b23e-10b96e4ef00d" // string | (optional)
tenantId := "38400000-8cf0-11bd-b23e-10b96e4ef00d" // string | (optional)
calculateTotalItems := true // bool | (optional)
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.TemplateAssignmentsApi.GetTemplateAssignmentsPage(context.Background()).Page(page).PageSize(pageSize).TemplateId(templateId).TenantId(tenantId).CalculateTotalItems(calculateTotalItems).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `TemplateAssignmentsApi.GetTemplateAssignmentsPage``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `GetTemplateAssignmentsPage`: TemplateAssignmentsPage
fmt.Fprintf(os.Stdout, "Response from `TemplateAssignmentsApi.GetTemplateAssignmentsPage`: %v\n", resp)
}
Other parameters are passed through a pointer to a apiGetTemplateAssignmentsPageRequest struct via the builder pattern
Name | Type | Description | Notes |
---|---|---|---|
page | int32 | ||
pageSize | int32 | ||
templateId | string | ||
tenantId | string | ||
calculateTotalItems | bool |
No authorization required
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
TemplateAssignment UpdateAssignmentStatus(ctx, id).TemplateAssignmentStatusPatch(templateAssignmentStatusPatch).Execute()
Updates a template assignment status.
package main
import (
"context"
"fmt"
"os"
openapiclient "./openapi"
)
func main() {
id := "38400000-8cf0-11bd-b23e-10b96e4ef00d" // string | ID of template assignment record.
templateAssignmentStatusPatch := *openapiclient.NewTemplateAssignmentStatusPatch(openapiclient.TemplateStatus("NEW")) // TemplateAssignmentStatusPatch |
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.TemplateAssignmentsApi.UpdateAssignmentStatus(context.Background(), id).TemplateAssignmentStatusPatch(templateAssignmentStatusPatch).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `TemplateAssignmentsApi.UpdateAssignmentStatus``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `UpdateAssignmentStatus`: TemplateAssignment
fmt.Fprintf(os.Stdout, "Response from `TemplateAssignmentsApi.UpdateAssignmentStatus`: %v\n", resp)
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
id | string | ID of template assignment record. |
Other parameters are passed through a pointer to a apiUpdateAssignmentStatusRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
templateAssignmentStatusPatch | TemplateAssignmentStatusPatch | |
No authorization required
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]