sailpoint.tags.TagsApi
All URIs are relative to https://sailpoint.api.identitynow.com
| Method | HTTP request | Description |
|---|---|---|
| create-tag-v1 | POST /tags/v1 | Create tag |
| delete-tag-by-id-v1 | DELETE /tags/v1/{id} | Delete tag |
| get-tag-by-id-v1 | GET /tags/v1/{id} | Get tag by id |
| list-tags-v1 | GET /tags/v1 | List tags |
create-tag-v1
Create tag This API creates new tag.
A token with API, ORG_ADMIN, CERT_ADMIN, REPORT_ADMIN, ROLE_ADMIN, ROLE_SUBADMIN, SOURCE_ADMIN, or SOURCE_SUBADMIN authority is required to call this API.
Parameters
| Param Type | Name | Data Type | Required | Description |
|---|---|---|---|---|
| Body | tag2 | Tag2 | True |
Return type
Responses
| Code | Description | Data Type | Response headers |
|---|---|---|---|
| 201 | Created tag. | Tag2 | - |
| 400 | Client Error - Returned if the request body is invalid. | Errorresponsedto | - |
| 401 | Unauthorized - Returned if there is no authorization header, or if the JWT token is expired. | ListTagsV1401Response | - |
| 403 | Forbidden - Returned if the user you are running as, doesn't have access to this end-point. | Errorresponsedto | - |
| 429 | Too Many Requests - Returned in response to too many requests in a given period of time - rate limited. The Retry-After header in the response includes how long to wait before trying again. | ListTagsV1429Response | - |
| 500 | Internal Server Error - Returned if there is an unexpected error. | Errorresponsedto | - |
HTTP request headers
- Content-Type: application/json
- Accept: application/json
Example
from sailpoint.tags.api.tags_api import TagsApi
from sailpoint.tags.api_client import ApiClient
from sailpoint.tags.models.tag2 import Tag2
from sailpoint.configuration import Configuration
configuration = Configuration()
with ApiClient(configuration) as api_client:
tag2 = '''sailpoint.tags.Tag2()''' # Tag2 |
try:
# Create tag
new_tag2 = Tag2.from_json(tag2)
results = TagsApi(api_client).create_tag_v1(tag2=new_tag2)
# Below is a request that includes all optional parameters
# results = TagsApi(api_client).create_tag_v1(new_tag2)
print("The response of TagsApi->create_tag_v1:\n")
print(results.model_dump_json(by_alias=True, indent=4))
except Exception as e:
print("Exception when calling TagsApi->create_tag_v1: %s\n" % e)
delete-tag-by-id-v1
Delete tag This API deletes a tag by specified id.
A token with API, ORG_ADMIN, CERT_ADMIN, REPORT_ADMIN, ROLE_ADMIN, ROLE_SUBADMIN, SOURCE_ADMIN, or SOURCE_SUBADMIN authority is required to call this API.
Parameters
| Param Type | Name | Data Type | Required | Description |
|---|---|---|---|---|
| Path | id | str | True | The ID of the object reference to delete. |
Return type
(empty response body)
Responses
| Code | Description | Data Type | Response headers |
|---|---|---|---|
| 204 | No content. | - | |
| 400 | Client Error - Returned if the request body is invalid. | Errorresponsedto | - |
| 401 | Unauthorized - Returned if there is no authorization header, or if the JWT token is expired. | ListTagsV1401Response | - |
| 403 | Forbidden - Returned if the user you are running as, doesn't have access to this end-point. | Errorresponsedto | - |
| 404 | Not Found - returned if the request URL refers to a resource or object that does not exist | Errorresponsedto | - |
| 429 | Too Many Requests - Returned in response to too many requests in a given period of time - rate limited. The Retry-After header in the response includes how long to wait before trying again. | ListTagsV1429Response | - |
| 500 | Internal Server Error - Returned if there is an unexpected error. | Errorresponsedto | - |
HTTP request headers
- Content-Type: Not defined
- Accept: application/json
Example
from sailpoint.tags.api.tags_api import TagsApi
from sailpoint.tags.api_client import ApiClient
from sailpoint.configuration import Configuration
configuration = Configuration()
with ApiClient(configuration) as api_client:
id = '329d96cf-3bdb-40a9-988a-b5037ab89022' # str | The ID of the object reference to delete. # str | The ID of the object reference to delete.
try:
# Delete tag
TagsApi(api_client).delete_tag_by_id_v1(id=id)
# Below is a request that includes all optional parameters
# TagsApi(api_client).delete_tag_by_id_v1(id)
except Exception as e:
print("Exception when calling TagsApi->delete_tag_by_id_v1: %s\n" % e)
get-tag-by-id-v1
Get tag by id Returns a tag by its id.
A token with API, ORG_ADMIN, CERT_ADMIN, REPORT_ADMIN, ROLE_ADMIN, ROLE_SUBADMIN, SOURCE_ADMIN, or SOURCE_SUBADMIN authority is required to call this API.
Parameters
| Param Type | Name | Data Type | Required | Description |
|---|---|---|---|---|
| Path | id | str | True | The ID of the object reference to retrieve. |
Return type
Responses
| Code | Description | Data Type | Response headers |
|---|---|---|---|
| 200 | Tag | Tag2 | - |
| 400 | Client Error - Returned if the request body is invalid. | Errorresponsedto | - |
| 401 | Unauthorized - Returned if there is no authorization header, or if the JWT token is expired. | ListTagsV1401Response | - |
| 403 | Forbidden - Returned if the user you are running as, doesn't have access to this end-point. | Errorresponsedto | - |
| 404 | Not Found - returned if the request URL refers to a resource or object that does not exist | Errorresponsedto | - |
| 429 | Too Many Requests - Returned in response to too many requests in a given period of time - rate limited. The Retry-After header in the response includes how long to wait before trying again. | ListTagsV1429Response | - |
| 500 | Internal Server Error - Returned if there is an unexpected error. | Errorresponsedto | - |
HTTP request headers
- Content-Type: Not defined
- Accept: application/json
Example
from sailpoint.tags.api.tags_api import TagsApi
from sailpoint.tags.api_client import ApiClient
from sailpoint.tags.models.tag2 import Tag2
from sailpoint.configuration import Configuration
configuration = Configuration()
with ApiClient(configuration) as api_client:
id = '329d96cf-3bdb-40a9-988a-b5037ab89022' # str | The ID of the object reference to retrieve. # str | The ID of the object reference to retrieve.
try:
# Get tag by id
results = TagsApi(api_client).get_tag_by_id_v1(id=id)
# Below is a request that includes all optional parameters
# results = TagsApi(api_client).get_tag_by_id_v1(id)
print("The response of TagsApi->get_tag_by_id_v1:\n")
print(results.model_dump_json(by_alias=True, indent=4))
except Exception as e:
print("Exception when calling TagsApi->get_tag_by_id_v1: %s\n" % e)
list-tags-v1
List tags This API returns a list of tags.
A token with API, ORG_ADMIN, CERT_ADMIN, REPORT_ADMIN, ROLE_ADMIN, ROLE_SUBADMIN, SOURCE_ADMIN, or SOURCE_SUBADMIN authority is required to call this API.
Parameters
| Param Type | Name | Data Type | Required | Description |
|---|---|---|---|---|
| Query | limit | int | (optional) (default to 250) | Max number of results to return. See V3 API Standard Collection Parameters for more information. |
| Query | offset | int | (optional) (default to 0) | Offset into the full result set. Usually specified with limit to paginate through the results. See V3 API Standard Collection Parameters for more information. |
| Query | count | bool | (optional) (default to False) | 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 for more information. |
| Query | filters | str | (optional) | Filter results using the standard syntax described in V3 API Standard Collection Parameters Filtering is supported for the following fields and operators: id: eq, in name: eq, in, sw |
| Query | sorters | str | (optional) | Sort results using the standard syntax described in V3 API Standard Collection Parameters Sorting is supported for the following fields: id, name, created, modified |
Return type
Responses
| Code | Description | Data Type | Response headers |
|---|---|---|---|
| 200 | List of all tags. | List[Tag2] | - |
| 400 | Client Error - Returned if the request body is invalid. | Errorresponsedto | - |
| 401 | Unauthorized - Returned if there is no authorization header, or if the JWT token is expired. | ListTagsV1401Response | - |
| 403 | Forbidden - Returned if the user you are running as, doesn't have access to this end-point. | Errorresponsedto | - |
| 429 | Too Many Requests - Returned in response to too many requests in a given period of time - rate limited. The Retry-After header in the response includes how long to wait before trying again. | ListTagsV1429Response | - |
| 500 | Internal Server Error - Returned if there is an unexpected error. | Errorresponsedto | - |
HTTP request headers
- Content-Type: Not defined
- Accept: application/json
Example
from sailpoint.tags.api.tags_api import TagsApi
from sailpoint.tags.api_client import ApiClient
from sailpoint.tags.models.tag2 import Tag2
from sailpoint.configuration import Configuration
configuration = Configuration()
with ApiClient(configuration) as api_client:
limit = 250 # int | 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) # int | 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 # int | 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) # int | 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)
count = 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) # 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)
filters = 'id eq \"27462f54-61c7-4140-b5da-d5dbe27fc6db\"' # str | 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* **name**: *eq, in, sw* (optional) # str | 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* **name**: *eq, in, sw* (optional)
sorters = 'name,-modified' # str | 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: **id, name, created, modified** (optional) # str | 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: **id, name, created, modified** (optional)
try:
# List tags
results = TagsApi(api_client).list_tags_v1()
# Below is a request that includes all optional parameters
# results = TagsApi(api_client).list_tags_v1(limit, offset, count, filters, sorters)
print("The response of TagsApi->list_tags_v1:\n")
for item in results:
print(item.model_dump_json(by_alias=True, indent=4))
except Exception as e:
print("Exception when calling TagsApi->list_tags_v1: %s\n" % e)