mirror of
https://github.com/LukeHagar/developer.sailpoint.com.git
synced 2025-12-09 04:19:37 +00:00
update go docs and examples
This commit is contained in:
@@ -67,16 +67,20 @@ import (
|
||||
"context"
|
||||
"fmt"
|
||||
"os"
|
||||
beta "github.com/sailpoint-oss/golang-sdk/v2/api_beta"
|
||||
openapiclient "github.com/sailpoint-oss/golang-sdk/v2"
|
||||
|
||||
|
||||
sailpoint "github.com/sailpoint-oss/golang-sdk/v2"
|
||||
)
|
||||
|
||||
func main() {
|
||||
id := 2c91808a7813090a017814121919ecca # string | ID of the Auth Profile to get. # string | ID of the Auth Profile to get.
|
||||
id := `2c91808a7813090a017814121919ecca` // string | ID of the Auth Profile to get. # string | ID of the Auth Profile to get.
|
||||
|
||||
configuration := NewDefaultConfiguration()
|
||||
apiClient := NewAPIClient(configuration)
|
||||
resp, r, err := apiClient.Beta.AuthProfileAPI.GetProfileConfig(context.Background(), id).Execute()
|
||||
|
||||
|
||||
configuration := sailpoint.NewDefaultConfiguration()
|
||||
apiClient := sailpoint.NewAPIClient(configuration)
|
||||
resp, r, err := apiClient.Beta.AuthProfileAPI.GetProfileConfig(context.Background(), id).Execute()
|
||||
//resp, r, err := apiClient.Beta.AuthProfileAPI.GetProfileConfig(context.Background(), id).Execute()
|
||||
if err != nil {
|
||||
fmt.Fprintf(os.Stderr, "Error when calling `AuthProfileAPI.GetProfileConfig``: %v\n", err)
|
||||
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
|
||||
@@ -121,15 +125,19 @@ import (
|
||||
"context"
|
||||
"fmt"
|
||||
"os"
|
||||
beta "github.com/sailpoint-oss/golang-sdk/v2/api_beta"
|
||||
openapiclient "github.com/sailpoint-oss/golang-sdk/v2"
|
||||
|
||||
|
||||
sailpoint "github.com/sailpoint-oss/golang-sdk/v2"
|
||||
)
|
||||
|
||||
func main() {
|
||||
|
||||
configuration := NewDefaultConfiguration()
|
||||
apiClient := NewAPIClient(configuration)
|
||||
resp, r, err := apiClient.Beta.AuthProfileAPI.GetProfileConfigList(context.Background()).Execute()
|
||||
|
||||
|
||||
configuration := sailpoint.NewDefaultConfiguration()
|
||||
apiClient := sailpoint.NewAPIClient(configuration)
|
||||
resp, r, err := apiClient.Beta.AuthProfileAPI.GetProfileConfigList(context.Background()).Execute()
|
||||
//resp, r, err := apiClient.Beta.AuthProfileAPI.GetProfileConfigList(context.Background()).Execute()
|
||||
if err != nil {
|
||||
fmt.Fprintf(os.Stderr, "Error when calling `AuthProfileAPI.GetProfileConfigList``: %v\n", err)
|
||||
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
|
||||
@@ -184,17 +192,27 @@ import (
|
||||
"context"
|
||||
"fmt"
|
||||
"os"
|
||||
beta "github.com/sailpoint-oss/golang-sdk/v2/api_beta"
|
||||
openapiclient "github.com/sailpoint-oss/golang-sdk/v2"
|
||||
"encoding/json"
|
||||
beta "github.com/sailpoint-oss/golang-sdk/v2/api_beta"
|
||||
sailpoint "github.com/sailpoint-oss/golang-sdk/v2"
|
||||
)
|
||||
|
||||
func main() {
|
||||
id := 2c91808a7813090a017814121919ecca # string | ID of the Auth Profile to patch. # string | ID of the Auth Profile to patch.
|
||||
jsonPatchOperation := fmt.Sprintf(``) # []JsonPatchOperation |
|
||||
id := `2c91808a7813090a017814121919ecca` // string | ID of the Auth Profile to patch. # string | ID of the Auth Profile to patch.
|
||||
jsonPatchOperation := fmt.Sprintf(``) // []JsonPatchOperation |
|
||||
|
||||
configuration := NewDefaultConfiguration()
|
||||
apiClient := NewAPIClient(configuration)
|
||||
resp, r, err := apiClient.Beta.AuthProfileAPI.PatchProfileConfig(context.Background(), id).JsonPatchOperation(jsonPatchOperation).Execute()
|
||||
|
||||
var jsonPatchOperation beta.JsonPatchOperation
|
||||
if err := json.Unmarshal(data, &jsonPatchOperation); err != nil {
|
||||
fmt.Println("Error:", err)
|
||||
return
|
||||
}
|
||||
|
||||
|
||||
configuration := sailpoint.NewDefaultConfiguration()
|
||||
apiClient := sailpoint.NewAPIClient(configuration)
|
||||
resp, r, err := apiClient.Beta.AuthProfileAPI.PatchProfileConfig(context.Background(), id).JsonPatchOperation(jsonPatchOperation).Execute()
|
||||
//resp, r, err := apiClient.Beta.AuthProfileAPI.PatchProfileConfig(context.Background(), id).JsonPatchOperation(jsonPatchOperation).Execute()
|
||||
if err != nil {
|
||||
fmt.Fprintf(os.Stderr, "Error when calling `AuthProfileAPI.PatchProfileConfig``: %v\n", err)
|
||||
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
|
||||
|
||||
Reference in New Issue
Block a user