Skip to content
This repository has been archived by the owner on Sep 10, 2024. It is now read-only.

Latest commit

 

History

History
296 lines (204 loc) · 8.4 KB

CredentialApi.md

File metadata and controls

296 lines (204 loc) · 8.4 KB

rapid7vmconsole.CredentialApi

All URIs are relative to https://localhost:3780

Method HTTP request Description
create_shared_credential POST /api/3/shared_credentials Shared Credentials
delete_all_shared_credentials DELETE /api/3/shared_credentials Shared Credentials
delete_shared_credential DELETE /api/3/shared_credentials/{id} Shared Credential
get_shared_credential GET /api/3/shared_credentials/{id} Shared Credential
get_shared_credentials GET /api/3/shared_credentials Shared Credentials
update_shared_credential PUT /api/3/shared_credentials/{id} Shared Credential

create_shared_credential

CreatedReferenceCredentialIDLink create_shared_credential(credential=credential)

Shared Credentials

Creates a new shared credential.

Example

from __future__ import print_function
import time
import rapid7vmconsole
from rapid7vmconsole.rest import ApiException
from pprint import pprint

# create an instance of the API class
api_instance = rapid7vmconsole.CredentialApi()
credential = rapid7vmconsole.SharedCredential() # SharedCredential | The specification of a shared credential. (optional)

try:
    # Shared Credentials
    api_response = api_instance.create_shared_credential(credential=credential)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling CredentialApi->create_shared_credential: %s\n" % e)

Parameters

Name Type Description Notes
credential SharedCredential The specification of a shared credential. [optional]

Return type

CreatedReferenceCredentialIDLink

Authorization

No authorization required

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json;charset=UTF-8

[Back to top] [Back to API list] [Back to Model list] [Back to README]

delete_all_shared_credentials

Links delete_all_shared_credentials()

Shared Credentials

Deletes all shared credentials.

Example

from __future__ import print_function
import time
import rapid7vmconsole
from rapid7vmconsole.rest import ApiException
from pprint import pprint

# create an instance of the API class
api_instance = rapid7vmconsole.CredentialApi()

try:
    # Shared Credentials
    api_response = api_instance.delete_all_shared_credentials()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling CredentialApi->delete_all_shared_credentials: %s\n" % e)

Parameters

This endpoint does not need any parameter.

Return type

Links

Authorization

No authorization required

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json;charset=UTF-8

[Back to top] [Back to API list] [Back to Model list] [Back to README]

delete_shared_credential

Links delete_shared_credential(id)

Shared Credential

Deletes the specified shared scan credential.

Example

from __future__ import print_function
import time
import rapid7vmconsole
from rapid7vmconsole.rest import ApiException
from pprint import pprint

# create an instance of the API class
api_instance = rapid7vmconsole.CredentialApi()
id = 56 # int | The identifier of the credential.

try:
    # Shared Credential
    api_response = api_instance.delete_shared_credential(id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling CredentialApi->delete_shared_credential: %s\n" % e)

Parameters

Name Type Description Notes
id int The identifier of the credential.

Return type

Links

Authorization

No authorization required

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json;charset=UTF-8

[Back to top] [Back to API list] [Back to Model list] [Back to README]

get_shared_credential

SharedCredential get_shared_credential(id)

Shared Credential

Retrieves the specified shared credential.

Example

from __future__ import print_function
import time
import rapid7vmconsole
from rapid7vmconsole.rest import ApiException
from pprint import pprint

# create an instance of the API class
api_instance = rapid7vmconsole.CredentialApi()
id = 56 # int | The identifier of the credential.

try:
    # Shared Credential
    api_response = api_instance.get_shared_credential(id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling CredentialApi->get_shared_credential: %s\n" % e)

Parameters

Name Type Description Notes
id int The identifier of the credential.

Return type

SharedCredential

Authorization

No authorization required

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json;charset=UTF-8

[Back to top] [Back to API list] [Back to Model list] [Back to README]

get_shared_credentials

ResourcesSharedCredential get_shared_credentials()

Shared Credentials

Retrieves all defined shared credential resources.

Example

from __future__ import print_function
import time
import rapid7vmconsole
from rapid7vmconsole.rest import ApiException
from pprint import pprint

# create an instance of the API class
api_instance = rapid7vmconsole.CredentialApi()

try:
    # Shared Credentials
    api_response = api_instance.get_shared_credentials()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling CredentialApi->get_shared_credentials: %s\n" % e)

Parameters

This endpoint does not need any parameter.

Return type

ResourcesSharedCredential

Authorization

No authorization required

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json;charset=UTF-8

[Back to top] [Back to API list] [Back to Model list] [Back to README]

update_shared_credential

Links update_shared_credential(id, credential=credential)

Shared Credential

Updates the specified shared credential.

Example

from __future__ import print_function
import time
import rapid7vmconsole
from rapid7vmconsole.rest import ApiException
from pprint import pprint

# create an instance of the API class
api_instance = rapid7vmconsole.CredentialApi()
id = 56 # int | The identifier of the credential.
credential = rapid7vmconsole.SharedCredential() # SharedCredential | The specification of the shared credential to update. (optional)

try:
    # Shared Credential
    api_response = api_instance.update_shared_credential(id, credential=credential)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling CredentialApi->update_shared_credential: %s\n" % e)

Parameters

Name Type Description Notes
id int The identifier of the credential.
credential SharedCredential The specification of the shared credential to update. [optional]

Return type

Links

Authorization

No authorization required

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json;charset=UTF-8

[Back to top] [Back to API list] [Back to Model list] [Back to README]