Skip to content

Commit

Permalink
feat(IAM Identity): add disable_api_key and enable_api_key operations (
Browse files Browse the repository at this point in the history
…#248)

Signed-off-by: Somanath Chavan <somanath.chavan@ibm.com>
  • Loading branch information
Somchavan authored Mar 26, 2024
1 parent 8ddcf7f commit b0b0ea8
Show file tree
Hide file tree
Showing 4 changed files with 1,749 additions and 1,352 deletions.
33 changes: 33 additions & 0 deletions examples/test_iam_identity_v1_examples.py
Original file line number Diff line number Diff line change
Expand Up @@ -317,6 +317,39 @@ def test_unlock_api_key_example(self):
except ApiException as e:
pytest.fail(str(e))

@needscredentials
def test_disable_api_key_example(self):
"""
disable_api_key request example
"""
try:
# begin-disable_api_key

response = iam_identity_service.disable_api_key(id=apikey_id)

# end-disable_api_key
print('\nlock_api_key() response status code: ', response.get_status_code())

except ApiException as e:
pytest.fail(str(e))

@needscredentials
def test_enable_api_key_example(self):
"""
enable_api_key request example
"""
try:
# begin-enable_api_key

response = iam_identity_service.enable_api_key(id=apikey_id)

# end-enable_api_key

print('\nunlock_api_key() response status code: ', response.get_status_code())

except ApiException as e:
pytest.fail(str(e))

@needscredentials
def test_delete_api_key_example(self):
"""
Expand Down
Loading

0 comments on commit b0b0ea8

Please sign in to comment.