All URIs are relative to https://app.koyeb.com
Method | HTTP request | Description |
---|---|---|
CreateCredential | Post /v1/credentials | Create credential |
DeleteCredential | Delete /v1/credentials/{id} | Delete credential |
GetCredential | Get /v1/credentials/{id} | Get credential |
ListCredentials | Get /v1/credentials | List credentials |
UpdateCredential | Put /v1/credentials/{id} | Update credential |
UpdateCredential2 | Patch /v1/credentials/{id} | Update credential |
CreateCredentialReply CreateCredential(ctx).Credential(credential).Execute()
Create credential
package main
import (
"context"
"fmt"
"os"
openapiclient "./openapi"
)
func main() {
credential := *openapiclient.NewCreateCredential() // CreateCredential |
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.CredentialsApi.CreateCredential(context.Background()).Credential(credential).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `CredentialsApi.CreateCredential``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `CreateCredential`: CreateCredentialReply
fmt.Fprintf(os.Stdout, "Response from `CredentialsApi.CreateCredential`: %v\n", resp)
}
Other parameters are passed through a pointer to a apiCreateCredentialRequest struct via the builder pattern
Name | Type | Description | Notes |
---|---|---|---|
credential | CreateCredential |
- Content-Type: Not defined
- Accept: /
[Back to top] [Back to API list] [Back to Model list] [Back to README]
map[string]interface{} DeleteCredential(ctx, id).Execute()
Delete credential
package main
import (
"context"
"fmt"
"os"
openapiclient "./openapi"
)
func main() {
id := "id_example" // string |
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.CredentialsApi.DeleteCredential(context.Background(), id).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `CredentialsApi.DeleteCredential``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `DeleteCredential`: map[string]interface{}
fmt.Fprintf(os.Stdout, "Response from `CredentialsApi.DeleteCredential`: %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 apiDeleteCredentialRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
map[string]interface{}
- Content-Type: Not defined
- Accept: /
[Back to top] [Back to API list] [Back to Model list] [Back to README]
GetCredentialReply GetCredential(ctx, id).Execute()
Get credential
package main
import (
"context"
"fmt"
"os"
openapiclient "./openapi"
)
func main() {
id := "id_example" // string |
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.CredentialsApi.GetCredential(context.Background(), id).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `CredentialsApi.GetCredential``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `GetCredential`: GetCredentialReply
fmt.Fprintf(os.Stdout, "Response from `CredentialsApi.GetCredential`: %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 apiGetCredentialRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
- Content-Type: Not defined
- Accept: /
[Back to top] [Back to API list] [Back to Model list] [Back to README]
ListCredentialsReply ListCredentials(ctx).Type_(type_).Name(name).OrganizationId(organizationId).UserId(userId).Limit(limit).Offset(offset).Execute()
List credentials
package main
import (
"context"
"fmt"
"os"
openapiclient "./openapi"
)
func main() {
type_ := "type__example" // string | (Optional) A filter for type (optional) (default to "INVALID")
name := "name_example" // string | (Optional) A filter for name (optional)
organizationId := "organizationId_example" // string | (Optional) Filter for an organization (optional)
userId := "userId_example" // string | (Optional) Filter for an user (optional)
limit := "limit_example" // string | (Optional) The number of items to return (optional)
offset := "offset_example" // string | (Optional) The offset in the list of item to return (optional)
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.CredentialsApi.ListCredentials(context.Background()).Type_(type_).Name(name).OrganizationId(organizationId).UserId(userId).Limit(limit).Offset(offset).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `CredentialsApi.ListCredentials``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `ListCredentials`: ListCredentialsReply
fmt.Fprintf(os.Stdout, "Response from `CredentialsApi.ListCredentials`: %v\n", resp)
}
Other parameters are passed through a pointer to a apiListCredentialsRequest struct via the builder pattern
Name | Type | Description | Notes |
---|---|---|---|
type_ | string | (Optional) A filter for type | [default to "INVALID"] |
name | string | (Optional) A filter for name | |
organizationId | string | (Optional) Filter for an organization | |
userId | string | (Optional) Filter for an user | |
limit | string | (Optional) The number of items to return | |
offset | string | (Optional) The offset in the list of item to return |
- Content-Type: Not defined
- Accept: /
[Back to top] [Back to API list] [Back to Model list] [Back to README]
UpdateCredentialReply UpdateCredential(ctx, id).Credential(credential).UpdateMask(updateMask).Execute()
Update credential
package main
import (
"context"
"fmt"
"os"
openapiclient "./openapi"
)
func main() {
id := "id_example" // string |
credential := *openapiclient.NewCredential() // Credential |
updateMask := "updateMask_example" // string | (optional)
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.CredentialsApi.UpdateCredential(context.Background(), id).Credential(credential).UpdateMask(updateMask).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `CredentialsApi.UpdateCredential``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `UpdateCredential`: UpdateCredentialReply
fmt.Fprintf(os.Stdout, "Response from `CredentialsApi.UpdateCredential`: %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 apiUpdateCredentialRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
credential | Credential | | updateMask | string | |
- Content-Type: Not defined
- Accept: /
[Back to top] [Back to API list] [Back to Model list] [Back to README]
UpdateCredentialReply UpdateCredential2(ctx, id).Credential(credential).UpdateMask(updateMask).Execute()
Update credential
package main
import (
"context"
"fmt"
"os"
openapiclient "./openapi"
)
func main() {
id := "id_example" // string |
credential := *openapiclient.NewCredential() // Credential |
updateMask := "updateMask_example" // string | (optional)
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.CredentialsApi.UpdateCredential2(context.Background(), id).Credential(credential).UpdateMask(updateMask).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `CredentialsApi.UpdateCredential2``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `UpdateCredential2`: UpdateCredentialReply
fmt.Fprintf(os.Stdout, "Response from `CredentialsApi.UpdateCredential2`: %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 apiUpdateCredential2Request struct via the builder pattern
Name | Type | Description | Notes |
---|
credential | Credential | | updateMask | string | |
- Content-Type: Not defined
- Accept: /
[Back to top] [Back to API list] [Back to Model list] [Back to README]