Skip to content
This repository was archived by the owner on Jan 12, 2021. It is now read-only.

Latest commit

 

History

History
271 lines (187 loc) · 10 KB

File metadata and controls

271 lines (187 loc) · 10 KB

esp_sdk.TeamsApi

All URIs are relative to https://api.evident.io

Method HTTP request Description
create POST /api/v2/teams.json_api Create a(n) Team
delete DELETE /api/v2/teams/{id}.json_api Delete a(n) Team
list PUT /api/v2/teams.json_api Get a list of Teams
show GET /api/v2/teams/{id}.json_api Show a single Team
update PATCH /api/v2/teams/{id}.json_api Update a(n) Team

create

Team create(name, sub_organization_id, include=include, report_interval=report_interval)

Create a(n) Team

Example

from __future__ import print_statement
import time
import esp_sdk
from esp_sdk.rest import ApiException
from pprint import pprint

# create an instance of the API class
api_instance = esp_sdk.TeamsApi()
name = 'name_example' # str | Name of the team
sub_organization_id = 56 # int | The ID of the sub organization to attach this team to
include = 'include_example' # str | Related objects that can be included in the response:  custom_signatures, external_accounts, organization, sub_organization See Including Objects for more information. (optional)
report_interval = 56 # int | The interval period in hours for Evident.io to run reports (optional)

try: 
    # Create a(n) Team
    api_response = api_instance.create(name, sub_organization_id, include=include, report_interval=report_interval)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling TeamsApi->create: %s\n" % e)

Parameters

Name Type Description Notes
name str Name of the team
sub_organization_id int The ID of the sub organization to attach this team to
include str Related objects that can be included in the response: custom_signatures, external_accounts, organization, sub_organization See Including Objects for more information. [optional]
report_interval int The interval period in hours for Evident.io to run reports [optional]

Return type

Team

Authorization

See https://github.com/EvidentSecurity/esp-sdk-python#set-your-hmac-security-keys

HTTP request headers

  • Content-Type: application/vnd.api+json
  • Accept: application/vnd.api+json

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

delete

Meta delete(id)

Delete a(n) Team

Example

from __future__ import print_statement
import time
import esp_sdk
from esp_sdk.rest import ApiException
from pprint import pprint

# create an instance of the API class
api_instance = esp_sdk.TeamsApi()
id = 56 # int | Team ID

try: 
    # Delete a(n) Team
    api_response = api_instance.delete(id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling TeamsApi->delete: %s\n" % e)

Parameters

Name Type Description Notes
id int Team ID

Return type

Meta

Authorization

See https://github.com/EvidentSecurity/esp-sdk-python#set-your-hmac-security-keys

HTTP request headers

  • Content-Type: application/vnd.api+json
  • Accept: application/vnd.api+json

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

list

PaginatedCollection list(include=include, filter=filter, page=page)

Get a list of Teams

Example

from __future__ import print_statement
import time
import esp_sdk
from esp_sdk.rest import ApiException
from pprint import pprint

# create an instance of the API class
api_instance = esp_sdk.TeamsApi()
include = 'include_example' # str | Related objects that can be included in the response:  custom_signatures, external_accounts, organization, sub_organization See Including Objects for more information. (optional)
filter = {'key': 'filter_example'} # dict(str, str) | Filter Params for Searching.  Equality Searchable Attributes: [id, name] Matching Searchable Attribute: [name]  Sortable Attributes: [name, updated_at, created_at, id] Searchable Associations: [organization, sub_organization, custom_signatures, integrations] See Searching Lists for more information. See the filter parameter of the association's list action to see what attributes are searchable on each association. See Conditions on Relationships in Searching Lists for more information. (optional)
page = '{:number=>1,+:size=>20}' # str | Page Number and Page Size.  Number is the page number of the collection to return, size is the number of items to return per page. (optional) (default to {:number=>1,+:size=>20})

try: 
    # Get a list of Teams
    api_response = api_instance.list(include=include, filter=filter, page=page)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling TeamsApi->list: %s\n" % e)

Parameters

Name Type Description Notes
include str Related objects that can be included in the response: custom_signatures, external_accounts, organization, sub_organization See Including Objects for more information. [optional]
filter dict(str, str) Filter Params for Searching. Equality Searchable Attributes: [id, name] Matching Searchable Attribute: [name] Sortable Attributes: [name, updated_at, created_at, id] Searchable Associations: [organization, sub_organization, custom_signatures, integrations] See Searching Lists for more information. See the filter parameter of the association's list action to see what attributes are searchable on each association. See Conditions on Relationships in Searching Lists for more information. [optional]
page str Page Number and Page Size. Number is the page number of the collection to return, size is the number of items to return per page. [optional] [default to {:number=>1,+:size=>20}]

Return type

PaginatedCollection

Authorization

See https://github.com/EvidentSecurity/esp-sdk-python#set-your-hmac-security-keys

HTTP request headers

  • Content-Type: application/vnd.api+json
  • Accept: application/vnd.api+json

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

show

Team show(id, include=include)

Show a single Team

Example

from __future__ import print_statement
import time
import esp_sdk
from esp_sdk.rest import ApiException
from pprint import pprint

# create an instance of the API class
api_instance = esp_sdk.TeamsApi()
id = 56 # int | Team ID
include = 'include_example' # str | Related objects that can be included in the response:  custom_signatures, external_accounts, organization, sub_organization See Including Objects for more information. (optional)

try: 
    # Show a single Team
    api_response = api_instance.show(id, include=include)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling TeamsApi->show: %s\n" % e)

Parameters

Name Type Description Notes
id int Team ID
include str Related objects that can be included in the response: custom_signatures, external_accounts, organization, sub_organization See Including Objects for more information. [optional]

Return type

Team

Authorization

See https://github.com/EvidentSecurity/esp-sdk-python#set-your-hmac-security-keys

HTTP request headers

  • Content-Type: application/vnd.api+json
  • Accept: application/vnd.api+json

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

update

Team update(id, include=include, name=name, report_interval=report_interval)

Update a(n) Team

Example

from __future__ import print_statement
import time
import esp_sdk
from esp_sdk.rest import ApiException
from pprint import pprint

# create an instance of the API class
api_instance = esp_sdk.TeamsApi()
id = 56 # int | Team ID
include = 'include_example' # str | Related objects that can be included in the response:  custom_signatures, external_accounts, organization, sub_organization See Including Objects for more information. (optional)
name = 'name_example' # str | Name of the team (optional)
report_interval = 56 # int | The interval period in hours for Evident.io to run reports (optional)

try: 
    # Update a(n) Team
    api_response = api_instance.update(id, include=include, name=name, report_interval=report_interval)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling TeamsApi->update: %s\n" % e)

Parameters

Name Type Description Notes
id int Team ID
include str Related objects that can be included in the response: custom_signatures, external_accounts, organization, sub_organization See Including Objects for more information. [optional]
name str Name of the team [optional]
report_interval int The interval period in hours for Evident.io to run reports [optional]

Return type

Team

Authorization

See https://github.com/EvidentSecurity/esp-sdk-python#set-your-hmac-security-keys

HTTP request headers

  • Content-Type: application/vnd.api+json
  • Accept: application/vnd.api+json

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