Skip to main content

MachineIdentitiesAPI

All URIs are relative to https://sailpoint.api.identitynow.com

MethodHTTP requestDescription
create-machine-identity-v1Post /machine-identities/v1Create machine identity
delete-machine-identity-v1Delete /machine-identities/v1/{id}Delete machine identity
get-machine-identity-v1Get /machine-identities/v1/{id}Get machine identity details
list-machine-identities-v1Get /machine-identities/v1List machine identities
list-machine-identity-user-entitlements-v1Get /machine-identity-user-entitlements/v1List machine identity's user entitlements
start-machine-identity-aggregation-v1Post /sources/v1/{sourceId}/aggregate-agentsStart machine identity aggregation
update-machine-identity-v1Patch /machine-identities/v1/{id}Update machine identity details

create-machine-identity-v1

experimental

This API is currently in an experimental state. The API is subject to change based on feedback and further testing. You must include the X-SailPoint-Experimental header and set it to true to use this endpoint.

setting x-sailpoint-experimental header

on the configuration object you can set the x-sailpoint-experimental header to `true' to enable all experimantl endpoints within the SDK. Example:

  configuration = Configuration()
configuration.Experimental = true

Create machine identity Use this API to create a machine identity. The maximum supported length for the description field is 2000 characters.

API Spec

Path Parameters

Other Parameters

Other parameters are passed through a pointer to a apiCreateMachineIdentityV1Request struct via the builder pattern

NameTypeDescriptionNotes
xSailPointExperimentalstringUse this header to enable this experimental API.[default to "true"]
machineidentityrequestMachineidentityrequest

Return type

Machineidentityresponse

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

Example

package main

import (
"context"
"fmt"
"os"
"encoding/json"
v1 "github.com/sailpoint-oss/golang-sdk/v3/machine_identities"
sailpoint "github.com/sailpoint-oss/golang-sdk/v3/machine_identities"
)

func main() {
xSailPointExperimental := `true` // string | Use this header to enable this experimental API. (default to "true") # string | Use this header to enable this experimental API. (default to "true")
machineidentityrequest := []byte(``) // Machineidentityrequest |

var machineidentityrequest v1.Machineidentityrequest
if err := json.Unmarshal(machineidentityrequest, &machineidentityrequest); err != nil {
fmt.Println("Error:", err)
return
}


configuration := sailpoint.NewDefaultConfiguration()
apiClient := sailpoint.NewAPIClient(configuration)
resp, r, err := apiClient.MachineIdentitiesAPI.CreateMachineIdentityV1(context.Background()).XSailPointExperimental(xSailPointExperimental).Machineidentityrequest(machineidentityrequest).Execute()
//resp, r, err := apiClient.MachineIdentitiesAPI.CreateMachineIdentityV1(context.Background()).XSailPointExperimental(xSailPointExperimental).Machineidentityrequest(machineidentityrequest).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `MachineIdentitiesAPI.CreateMachineIdentityV1``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `CreateMachineIdentityV1`: Machineidentityresponse
fmt.Fprintf(os.Stdout, "Response from `MachineIdentitiesAPI.CreateMachineIdentityV1`: %v\n", resp)
}

[Back to top]

delete-machine-identity-v1

experimental

This API is currently in an experimental state. The API is subject to change based on feedback and further testing. You must include the X-SailPoint-Experimental header and set it to true to use this endpoint.

setting x-sailpoint-experimental header

on the configuration object you can set the x-sailpoint-experimental header to `true' to enable all experimantl endpoints within the SDK. Example:

  configuration = Configuration()
configuration.Experimental = true

Delete machine identity The API returns successful response if the requested machine identity was deleted.

API Spec

Path Parameters

NameTypeDescriptionNotes
ctxcontext.Contextcontext for authentication, logging, cancellation, deadlines, tracing, etc.
idstringMachine Identity ID

Other Parameters

Other parameters are passed through a pointer to a apiDeleteMachineIdentityV1Request struct via the builder pattern

NameTypeDescriptionNotes

xSailPointExperimental | string | Use this header to enable this experimental API. | [default to "true"]

Return type

(empty response body)

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

Example

package main

import (
"context"
"fmt"
"os"


sailpoint "github.com/sailpoint-oss/golang-sdk/v3/machine_identities"
)

func main() {
id := `ef38f94347e94562b5bb8424a56397d8` // string | Machine Identity ID # string | Machine Identity ID
xSailPointExperimental := `true` // string | Use this header to enable this experimental API. (default to "true") # string | Use this header to enable this experimental API. (default to "true")



configuration := sailpoint.NewDefaultConfiguration()
apiClient := sailpoint.NewAPIClient(configuration)
r, err := apiClient.MachineIdentitiesAPI.DeleteMachineIdentityV1(context.Background(), id).XSailPointExperimental(xSailPointExperimental).Execute()
//r, err := apiClient.MachineIdentitiesAPI.DeleteMachineIdentityV1(context.Background(), id).XSailPointExperimental(xSailPointExperimental).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `MachineIdentitiesAPI.DeleteMachineIdentityV1``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}

}

[Back to top]

get-machine-identity-v1

experimental

This API is currently in an experimental state. The API is subject to change based on feedback and further testing. You must include the X-SailPoint-Experimental header and set it to true to use this endpoint.

setting x-sailpoint-experimental header

on the configuration object you can set the x-sailpoint-experimental header to `true' to enable all experimantl endpoints within the SDK. Example:

  configuration = Configuration()
configuration.Experimental = true

Get machine identity details This API returns a single machine identity using the Machine Identity ID.

API Spec

Path Parameters

NameTypeDescriptionNotes
ctxcontext.Contextcontext for authentication, logging, cancellation, deadlines, tracing, etc.
idstringMachine Identity ID

Other Parameters

Other parameters are passed through a pointer to a apiGetMachineIdentityV1Request struct via the builder pattern

NameTypeDescriptionNotes

xSailPointExperimental | string | Use this header to enable this experimental API. | [default to "true"]

Return type

Machineidentityresponse

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

Example

package main

import (
"context"
"fmt"
"os"


sailpoint "github.com/sailpoint-oss/golang-sdk/v3/machine_identities"
)

func main() {
id := `ef38f94347e94562b5bb8424a56397d8` // string | Machine Identity ID # string | Machine Identity ID
xSailPointExperimental := `true` // string | Use this header to enable this experimental API. (default to "true") # string | Use this header to enable this experimental API. (default to "true")



configuration := sailpoint.NewDefaultConfiguration()
apiClient := sailpoint.NewAPIClient(configuration)
resp, r, err := apiClient.MachineIdentitiesAPI.GetMachineIdentityV1(context.Background(), id).XSailPointExperimental(xSailPointExperimental).Execute()
//resp, r, err := apiClient.MachineIdentitiesAPI.GetMachineIdentityV1(context.Background(), id).XSailPointExperimental(xSailPointExperimental).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `MachineIdentitiesAPI.GetMachineIdentityV1``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `GetMachineIdentityV1`: Machineidentityresponse
fmt.Fprintf(os.Stdout, "Response from `MachineIdentitiesAPI.GetMachineIdentityV1`: %v\n", resp)
}

[Back to top]

list-machine-identities-v1

experimental

This API is currently in an experimental state. The API is subject to change based on feedback and further testing. You must include the X-SailPoint-Experimental header and set it to true to use this endpoint.

setting x-sailpoint-experimental header

on the configuration object you can set the x-sailpoint-experimental header to `true' to enable all experimantl endpoints within the SDK. Example:

  configuration = Configuration()
configuration.Experimental = true

List machine identities This API returns a list of machine identities.

API Spec

Path Parameters

Other Parameters

Other parameters are passed through a pointer to a apiListMachineIdentitiesV1Request struct via the builder pattern

NameTypeDescriptionNotes
xSailPointExperimentalstringUse this header to enable this experimental API.[default to "true"]
filtersstringFilter results using the standard syntax described in V3 API Standard Collection Parameters Filtering is supported for the following fields and operators: id: eq, in, sw displayName: eq, in, sw cisIdentityId: eq, in, sw nativeIdentity: eq, in, sw attributes: eq manuallyEdited: eq subtype: eq, in owners.primaryIdentity.id: eq, in, sw owners.primaryIdentity.name: eq, in, isnull, pr owners.secondaryIdentity.id: eq, in, sw owners.secondaryIdentity.name: eq, in, isnull, pr source.name: eq, in, sw source.id: eq, in entitlement.id: eq, in entitlement.name: eq, in, sw
sortersstringSort results using the standard syntax described in V3 API Standard Collection Parameters Sorting is supported for the following fields: nativeIdentity, name, owners.primaryIdentity.name, source.name, created, modified
countboolIf true it will populate the X-Total-Count response header with the number of results that would be returned if limit and offset were ignored. Since requesting a total count can have a performance impact, it is recommended not to send count=true if that value will not be used. See V3 API Standard Collection Parameters for more information.[default to false]
limitint32Max number of results to return. See V3 API Standard Collection Parameters for more information.[default to 250]
offsetint32Offset into the full result set. Usually specified with limit to paginate through the results. See V3 API Standard Collection Parameters for more information.[default to 0]

Return type

[]Machineidentityresponse

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

Example

package main

import (
"context"
"fmt"
"os"


sailpoint "github.com/sailpoint-oss/golang-sdk/v3/machine_identities"
)

func main() {
xSailPointExperimental := `true` // string | Use this header to enable this experimental API. (default to "true") # string | Use this header to enable this experimental API. (default to "true")
filters := `identityId eq "2c9180858082150f0180893dbaf44201"` // string | Filter results using the standard syntax described in [V3 API Standard Collection Parameters](https://developer.sailpoint.com/idn/api/standard-collection-parameters#filtering-results) Filtering is supported for the following fields and operators: **id**: *eq, in, sw* **displayName**: *eq, in, sw* **cisIdentityId**: *eq, in, sw* **nativeIdentity**: *eq, in, sw* **attributes**: *eq* **manuallyEdited**: *eq* **subtype**: *eq, in* **owners.primaryIdentity.id**: *eq, in, sw* **owners.primaryIdentity.name**: *eq, in, isnull, pr* **owners.secondaryIdentity.id**: *eq, in, sw* **owners.secondaryIdentity.name**: *eq, in, isnull, pr* **source.name**: *eq, in, sw* **source.id**: *eq, in* **entitlement.id**: *eq, in* **entitlement.name**: *eq, in, sw* (optional) # string | Filter results using the standard syntax described in [V3 API Standard Collection Parameters](https://developer.sailpoint.com/idn/api/standard-collection-parameters#filtering-results) Filtering is supported for the following fields and operators: **id**: *eq, in, sw* **displayName**: *eq, in, sw* **cisIdentityId**: *eq, in, sw* **nativeIdentity**: *eq, in, sw* **attributes**: *eq* **manuallyEdited**: *eq* **subtype**: *eq, in* **owners.primaryIdentity.id**: *eq, in, sw* **owners.primaryIdentity.name**: *eq, in, isnull, pr* **owners.secondaryIdentity.id**: *eq, in, sw* **owners.secondaryIdentity.name**: *eq, in, isnull, pr* **source.name**: *eq, in, sw* **source.id**: *eq, in* **entitlement.id**: *eq, in* **entitlement.name**: *eq, in, sw* (optional)
sorters := `nativeIdentity` // string | Sort results using the standard syntax described in [V3 API Standard Collection Parameters](https://developer.sailpoint.com/idn/api/standard-collection-parameters#sorting-results) Sorting is supported for the following fields: **nativeIdentity, name, owners.primaryIdentity.name, source.name, created, modified** (optional) # string | Sort results using the standard syntax described in [V3 API Standard Collection Parameters](https://developer.sailpoint.com/idn/api/standard-collection-parameters#sorting-results) Sorting is supported for the following fields: **nativeIdentity, name, owners.primaryIdentity.name, source.name, created, modified** (optional)
count := true // bool | If *true* it will populate the *X-Total-Count* response header with the number of results that would be returned if *limit* and *offset* were ignored. Since requesting a total count can have a performance impact, it is recommended not to send **count=true** if that value will not be used. See [V3 API Standard Collection Parameters](https://developer.sailpoint.com/idn/api/standard-collection-parameters) for more information. (optional) (default to false) # bool | If *true* it will populate the *X-Total-Count* response header with the number of results that would be returned if *limit* and *offset* were ignored. Since requesting a total count can have a performance impact, it is recommended not to send **count=true** if that value will not be used. See [V3 API Standard Collection Parameters](https://developer.sailpoint.com/idn/api/standard-collection-parameters) for more information. (optional) (default to false)
limit := 250 // int32 | Max number of results to return. See [V3 API Standard Collection Parameters](https://developer.sailpoint.com/idn/api/standard-collection-parameters) for more information. (optional) (default to 250) # int32 | Max number of results to return. See [V3 API Standard Collection Parameters](https://developer.sailpoint.com/idn/api/standard-collection-parameters) for more information. (optional) (default to 250)
offset := 0 // int32 | Offset into the full result set. Usually specified with *limit* to paginate through the results. See [V3 API Standard Collection Parameters](https://developer.sailpoint.com/idn/api/standard-collection-parameters) for more information. (optional) (default to 0) # int32 | Offset into the full result set. Usually specified with *limit* to paginate through the results. See [V3 API Standard Collection Parameters](https://developer.sailpoint.com/idn/api/standard-collection-parameters) for more information. (optional) (default to 0)



configuration := sailpoint.NewDefaultConfiguration()
apiClient := sailpoint.NewAPIClient(configuration)
resp, r, err := apiClient.MachineIdentitiesAPI.ListMachineIdentitiesV1(context.Background()).XSailPointExperimental(xSailPointExperimental).Execute()
//resp, r, err := apiClient.MachineIdentitiesAPI.ListMachineIdentitiesV1(context.Background()).XSailPointExperimental(xSailPointExperimental).Filters(filters).Sorters(sorters).Count(count).Limit(limit).Offset(offset).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `MachineIdentitiesAPI.ListMachineIdentitiesV1``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `ListMachineIdentitiesV1`: []Machineidentityresponse
fmt.Fprintf(os.Stdout, "Response from `MachineIdentitiesAPI.ListMachineIdentitiesV1`: %v\n", resp)
}

[Back to top]

list-machine-identity-user-entitlements-v1

experimental

This API is currently in an experimental state. The API is subject to change based on feedback and further testing. You must include the X-SailPoint-Experimental header and set it to true to use this endpoint.

setting x-sailpoint-experimental header

on the configuration object you can set the x-sailpoint-experimental header to `true' to enable all experimantl endpoints within the SDK. Example:

  configuration = Configuration()
configuration.Experimental = true

List machine identity's user entitlements This API returns a list of user entitlements associated with machine identities.

API Spec

Path Parameters

Other Parameters

Other parameters are passed through a pointer to a apiListMachineIdentityUserEntitlementsV1Request struct via the builder pattern

NameTypeDescriptionNotes
xSailPointExperimentalstringUse this header to enable this experimental API.[default to "true"]
filtersstringFilter results using the standard syntax described in V3 API Standard Collection Parameters Filtering is supported for the following fields and operators: machineIdentityId: eq, in machineIdentityName: eq, in, sw entitlement.id: eq, in entitlement.name: eq, in, sw source.id: eq, in source.name: eq, in, sw
sortersstringSort results using the standard syntax described in V3 API Standard Collection Parameters Sorting is supported for the following fields: machineIdentityName, entitlement.name, source.name
countboolIf true it will populate the X-Total-Count response header with the number of results that would be returned if limit and offset were ignored. Since requesting a total count can have a performance impact, it is recommended not to send count=true if that value will not be used. See V3 API Standard Collection Parameters for more information.[default to false]
limitint32Max number of results to return. See V3 API Standard Collection Parameters for more information.[default to 250]
offsetint32Offset into the full result set. Usually specified with limit to paginate through the results. See V3 API Standard Collection Parameters for more information.[default to 0]

Return type

[]Machineidentityuserentitlementresponse

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

Example

package main

import (
"context"
"fmt"
"os"


sailpoint "github.com/sailpoint-oss/golang-sdk/v3/machine_identities"
)

func main() {
xSailPointExperimental := `true` // string | Use this header to enable this experimental API. (default to "true") # string | Use this header to enable this experimental API. (default to "true")
filters := `machineIdentityId eq "2c9180858082150f0180893dbaf44201"` // string | Filter results using the standard syntax described in [V3 API Standard Collection Parameters](https://developer.sailpoint.com/idn/api/standard-collection-parameters#filtering-results) Filtering is supported for the following fields and operators: **machineIdentityId**: *eq, in* **machineIdentityName**: *eq, in, sw* **entitlement.id**: *eq, in* **entitlement.name**: *eq, in, sw* **source.id**: *eq, in* **source.name**: *eq, in, sw* (optional) # string | Filter results using the standard syntax described in [V3 API Standard Collection Parameters](https://developer.sailpoint.com/idn/api/standard-collection-parameters#filtering-results) Filtering is supported for the following fields and operators: **machineIdentityId**: *eq, in* **machineIdentityName**: *eq, in, sw* **entitlement.id**: *eq, in* **entitlement.name**: *eq, in, sw* **source.id**: *eq, in* **source.name**: *eq, in, sw* (optional)
sorters := `machineIdentityName` // string | Sort results using the standard syntax described in [V3 API Standard Collection Parameters](https://developer.sailpoint.com/idn/api/standard-collection-parameters#sorting-results) Sorting is supported for the following fields: **machineIdentityName, entitlement.name, source.name** (optional) # string | Sort results using the standard syntax described in [V3 API Standard Collection Parameters](https://developer.sailpoint.com/idn/api/standard-collection-parameters#sorting-results) Sorting is supported for the following fields: **machineIdentityName, entitlement.name, source.name** (optional)
count := true // bool | If *true* it will populate the *X-Total-Count* response header with the number of results that would be returned if *limit* and *offset* were ignored. Since requesting a total count can have a performance impact, it is recommended not to send **count=true** if that value will not be used. See [V3 API Standard Collection Parameters](https://developer.sailpoint.com/idn/api/standard-collection-parameters) for more information. (optional) (default to false) # bool | If *true* it will populate the *X-Total-Count* response header with the number of results that would be returned if *limit* and *offset* were ignored. Since requesting a total count can have a performance impact, it is recommended not to send **count=true** if that value will not be used. See [V3 API Standard Collection Parameters](https://developer.sailpoint.com/idn/api/standard-collection-parameters) for more information. (optional) (default to false)
limit := 250 // int32 | Max number of results to return. See [V3 API Standard Collection Parameters](https://developer.sailpoint.com/idn/api/standard-collection-parameters) for more information. (optional) (default to 250) # int32 | Max number of results to return. See [V3 API Standard Collection Parameters](https://developer.sailpoint.com/idn/api/standard-collection-parameters) for more information. (optional) (default to 250)
offset := 0 // int32 | Offset into the full result set. Usually specified with *limit* to paginate through the results. See [V3 API Standard Collection Parameters](https://developer.sailpoint.com/idn/api/standard-collection-parameters) for more information. (optional) (default to 0) # int32 | Offset into the full result set. Usually specified with *limit* to paginate through the results. See [V3 API Standard Collection Parameters](https://developer.sailpoint.com/idn/api/standard-collection-parameters) for more information. (optional) (default to 0)



configuration := sailpoint.NewDefaultConfiguration()
apiClient := sailpoint.NewAPIClient(configuration)
resp, r, err := apiClient.MachineIdentitiesAPI.ListMachineIdentityUserEntitlementsV1(context.Background()).XSailPointExperimental(xSailPointExperimental).Execute()
//resp, r, err := apiClient.MachineIdentitiesAPI.ListMachineIdentityUserEntitlementsV1(context.Background()).XSailPointExperimental(xSailPointExperimental).Filters(filters).Sorters(sorters).Count(count).Limit(limit).Offset(offset).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `MachineIdentitiesAPI.ListMachineIdentityUserEntitlementsV1``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `ListMachineIdentityUserEntitlementsV1`: []Machineidentityuserentitlementresponse
fmt.Fprintf(os.Stdout, "Response from `MachineIdentitiesAPI.ListMachineIdentityUserEntitlementsV1`: %v\n", resp)
}

[Back to top]

start-machine-identity-aggregation-v1

experimental

This API is currently in an experimental state. The API is subject to change based on feedback and further testing. You must include the X-SailPoint-Experimental header and set it to true to use this endpoint.

setting x-sailpoint-experimental header

on the configuration object you can set the x-sailpoint-experimental header to `true' to enable all experimantl endpoints within the SDK. Example:

  configuration = Configuration()
configuration.Experimental = true

Start machine identity aggregation Starts a machine identity (AI Agents) aggregation on the specified source.

API Spec

Path Parameters

NameTypeDescriptionNotes
ctxcontext.Contextcontext for authentication, logging, cancellation, deadlines, tracing, etc.
sourceIdstringSource ID.

Other Parameters

Other parameters are passed through a pointer to a apiStartMachineIdentityAggregationV1Request struct via the builder pattern

NameTypeDescriptionNotes

xSailPointExperimental | string | Use this header to enable this experimental API. | [default to "true"] machineidentityaggregationrequest | Machineidentityaggregationrequest | |

Return type

Machineidentityaggregationresponse

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

Example

package main

import (
"context"
"fmt"
"os"
"encoding/json"
v1 "github.com/sailpoint-oss/golang-sdk/v3/machine_identities"
sailpoint "github.com/sailpoint-oss/golang-sdk/v3/machine_identities"
)

func main() {
sourceId := `ef38f94347e94562b5bb8424a56397d8` // string | Source ID. # string | Source ID.
xSailPointExperimental := `true` // string | Use this header to enable this experimental API. (default to "true") # string | Use this header to enable this experimental API. (default to "true")
machineidentityaggregationrequest := []byte(``) // Machineidentityaggregationrequest |

var machineidentityaggregationrequest v1.Machineidentityaggregationrequest
if err := json.Unmarshal(machineidentityaggregationrequest, &machineidentityaggregationrequest); err != nil {
fmt.Println("Error:", err)
return
}


configuration := sailpoint.NewDefaultConfiguration()
apiClient := sailpoint.NewAPIClient(configuration)
resp, r, err := apiClient.MachineIdentitiesAPI.StartMachineIdentityAggregationV1(context.Background(), sourceId).XSailPointExperimental(xSailPointExperimental).Machineidentityaggregationrequest(machineidentityaggregationrequest).Execute()
//resp, r, err := apiClient.MachineIdentitiesAPI.StartMachineIdentityAggregationV1(context.Background(), sourceId).XSailPointExperimental(xSailPointExperimental).Machineidentityaggregationrequest(machineidentityaggregationrequest).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `MachineIdentitiesAPI.StartMachineIdentityAggregationV1``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `StartMachineIdentityAggregationV1`: Machineidentityaggregationresponse
fmt.Fprintf(os.Stdout, "Response from `MachineIdentitiesAPI.StartMachineIdentityAggregationV1`: %v\n", resp)
}

[Back to top]

update-machine-identity-v1

experimental

This API is currently in an experimental state. The API is subject to change based on feedback and further testing. You must include the X-SailPoint-Experimental header and set it to true to use this endpoint.

setting x-sailpoint-experimental header

on the configuration object you can set the x-sailpoint-experimental header to `true' to enable all experimantl endpoints within the SDK. Example:

  configuration = Configuration()
configuration.Experimental = true

Update machine identity details Use this API to update machine identity details.

API Spec

Path Parameters

NameTypeDescriptionNotes
ctxcontext.Contextcontext for authentication, logging, cancellation, deadlines, tracing, etc.
idstringMachine Identity ID.

Other Parameters

Other parameters are passed through a pointer to a apiUpdateMachineIdentityV1Request struct via the builder pattern

NameTypeDescriptionNotes

xSailPointExperimental | string | Use this header to enable this experimental API. | [default to "true"] requestBody | []map[string]interface | A JSON of updated values JSON Patch standard. |

Return type

Machineidentityresponse

HTTP request headers

  • Content-Type: application/json-patch+json
  • Accept: application/json

Example

package main

import (
"context"
"fmt"
"os"
"encoding/json"
v1 "github.com/sailpoint-oss/golang-sdk/v3/machine_identities"
sailpoint "github.com/sailpoint-oss/golang-sdk/v3/machine_identities"
)

func main() {
id := `ef38f94347e94562b5bb8424a56397d8` // string | Machine Identity ID. # string | Machine Identity ID.
xSailPointExperimental := `true` // string | Use this header to enable this experimental API. (default to "true") # string | Use this header to enable this experimental API. (default to "true")
requestbody := []byte(`[{"op":"add","path":"/attributes/securityRisk","value":"medium"}]`) // []map[string]interface{} | A JSON of updated values [JSON Patch](https://tools.ietf.org/html/rfc6902) standard.

var requestBody []v1.RequestBody
if err := json.Unmarshal(requestbody, &requestBody); err != nil {
fmt.Println("Error:", err)
return
}


configuration := sailpoint.NewDefaultConfiguration()
apiClient := sailpoint.NewAPIClient(configuration)
resp, r, err := apiClient.MachineIdentitiesAPI.UpdateMachineIdentityV1(context.Background(), id).XSailPointExperimental(xSailPointExperimental).RequestBody(requestBody).Execute()
//resp, r, err := apiClient.MachineIdentitiesAPI.UpdateMachineIdentityV1(context.Background(), id).XSailPointExperimental(xSailPointExperimental).RequestBody(requestBody).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `MachineIdentitiesAPI.UpdateMachineIdentityV1``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `UpdateMachineIdentityV1`: Machineidentityresponse
fmt.Fprintf(os.Stdout, "Response from `MachineIdentitiesAPI.UpdateMachineIdentityV1`: %v\n", resp)
}

[Back to top]