Skip to content

kumoroku/go-sumologic

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Go API client for openapi

Getting Started

Welcome to the Sumo Logic API reference. You can use these APIs to interact with the Sumo Logic platform. For information on the collector and search APIs see our API home page.

API Endpoints

Sumo Logic has several deployments in different geographic locations. You'll need to use the Sumo Logic API endpoint corresponding to your geographic location. See the table below for the different API endpoints by deployment. For details determining your account's deployment see API endpoints.

Deployment Endpoint
AU https://api.au.sumologic.com/api/
CA https://api.ca.sumologic.com/api/
DE https://api.de.sumologic.com/api/
EU https://api.eu.sumologic.com/api/
FED https://api.fed.sumologic.com/api/
IN https://api.in.sumologic.com/api/
JP https://api.jp.sumologic.com/api/
US1 https://api.sumologic.com/api/
US2 https://api.us2.sumologic.com/api/

Authentication

Sumo Logic supports the following options for API authentication:

  • Access ID and Access Key
  • Base64 encoded Access ID and Access Key

See Access Keys to generate an Access Key. Make sure to copy the key you create, because it is displayed only once. When you have an Access ID and Access Key you can execute requests such as the following:

curl -u \"<accessId>:<accessKey>\" -X GET https://api.<deployment>.sumologic.com/api/v1/users

Where deployment is either au, ca, de, eu, fed, in, jp, us1, or us2. See API endpoints for details.

If you prefer to use basic access authentication, you can do a Base64 encoding of your <accessId>:<accessKey> to authenticate your HTTPS request. The following is an example request, replace the placeholder <encoded> with your encoded Access ID and Access Key string:

curl -H \"Authorization: Basic <encoded>\" -X GET https://api.<deployment>.sumologic.com/api/v1/users

Refer to API Authentication for a Base64 example.

Status Codes

Generic status codes that apply to all our APIs. See the HTTP status code registry for reference.

HTTP Status Code Error Code Description
301 moved The requested resource SHOULD be accessed through returned URI in Location Header. See [troubleshooting](https://help.sumologic.com/APIs/Troubleshooting-APIs/API-301-Error-Moved) for details.
401 unauthorized Credential could not be verified.
403 forbidden This operation is not allowed for your account type or the user doesn't have the role capability to perform this action. See [troubleshooting](https://help.sumologic.com/APIs/Troubleshooting-APIs/API-403-Error-This-operation-is-not-allowed-for-your-account-type) for details.
404 notfound Requested resource could not be found.
405 method.unsupported Unsupported method for URL.
415 contenttype.invalid Invalid content type.
429 rate.limit.exceeded The API request rate is higher than 4 request per second or inflight API requests are higher than 10 request per second.
500 internal.error Internal server error.
503 service.unavailable Service is currently unavailable.

Filtering

Some API endpoints support filtering results on a specified set of fields. Each endpoint that supports filtering will list the fields that can be filtered. Multiple fields can be combined by using an ampersand & character.

For example, to get 20 users whose firstName is John and lastName is Doe:

api.sumologic.com/v1/users?limit=20&firstName=John&lastName=Doe

Sorting

Some API endpoints support sorting fields by using the sortBy query parameter. The default sort order is ascending. Prefix the field with a minus sign - to sort in descending order.

For example, to get 20 users sorted by their email in descending order:

api.sumologic.com/v1/users?limit=20&sort=-email

Asynchronous Request

Asynchronous requests do not wait for results, instead they immediately respond back with a job identifier while the job runs in the background. You can use the job identifier to track the status of the asynchronous job request. Here is a typical flow for an asynchronous request.

  1. Start an asynchronous job. On success, a job identifier is returned. The job identifier uniquely identifies your asynchronous job.

  2. Once started, use the job identifier from step 1 to track the status of your asynchronous job. An asynchronous request will typically provide an endpoint to poll for the status of asynchronous job. A successful response from the status endpoint will have the following structure:

{
    \"status\": \"Status of asynchronous request\",
    \"statusMessage\": \"Optional message with additional information in case request succeeds\",
    \"error\": \"Error object in case request fails\"
}

The status field can have one of the following values: 1. Success: The job succeeded. The statusMessage field might have additional information. 2. InProgress: The job is still running. 3. Failed: The job failed. The error field in the response will have more information about the failure.

  1. Some asynchronous APIs may provide a third endpoint (like export result) to fetch the result of an asynchronous job.

Example

Let's say we want to export a folder with the identifier 0000000006A2E86F. We will use the async export API to export all the content under the folder with id=0000000006A2E86F.

  1. Start an export job for the folder
curl -X POST -u \"<accessId>:<accessKey>\" https://api.<deployment>.sumologic.com/api/v2/content/0000000006A2E86F/export

See authentication section for more details about accessId, accessKey, and deployment. On success, you will get back a job identifier. In the response below, C03E086C137F38B4 is the job identifier.

{
    \"id\": \"C03E086C137F38B4\"
}
  1. Now poll for the status of the asynchronous job with the status endpoint.
curl -X GET -u \"<accessId>:<accessKey>\" https://api.<deployment>.sumologic.com/api/v2/content/0000000006A2E86F/export/C03E086C137F38B4/status

You may get a response like

{
    \"status\": \"InProgress\",
    \"statusMessage\": null,
    \"error\": null
}

It implies the job is still in progress. Keep polling till the status is either Success or Failed.

  1. When the asynchronous job completes (status != \"InProgress\"), you can fetch the results with the export result endpoint.
curl -X GET -u \"<accessId>:<accessKey>\" https://api.<deployment>.sumologic.com/api/v2/content/0000000006A2E86F/export/C03E086C137F38B4/result

The asynchronous job may fail (status == \"Failed\"). You can look at the error field for more details.

{
    \"status\": \"Failed\",
    \"errors\": {
        \"code\": \"content1:too_many_items\",
        \"message\": \"Too many objects: object count(1100) was greater than limit 1000\"
    }
}

Rate Limiting

  • A rate limit of four API requests per second (240 requests per minute) applies to all API calls from a user.
  • A rate limit of 10 concurrent requests to any API endpoint applies to an access key.

If a rate is exceeded, a rate limit exceeded 429 status code is returned.

Generating Clients

You can use OpenAPI Generator to generate clients from the YAML file to access the API.

Using NPM

  1. Install NPM package wrapper globally, exposing the CLI on the command line:
npm install @openapitools/openapi-generator-cli -g

You can see detailed instructions here.

  1. Download the YAML file and save it locally. Let's say the file is saved as sumologic-api.yaml.
  2. Use the following command to generate python client inside the sumo/client/python directory:
openapi-generator generate -i sumologic-api.yaml -g python -o sumo/client/python

Using Homebrew

  1. Install OpenAPI Generator
brew install openapi-generator
  1. Download the YAML file and save it locally. Let's say the file is saved as sumologic-api.yaml.
  2. Use the following command to generate python client side code inside the sumo/client/python directory:
openapi-generator generate -i sumologic-api.yaml -g python -o sumo/client/python

Overview

This API client was generated by the OpenAPI Generator project. By using the OpenAPI-spec from a remote server, you can easily generate an API client.

  • API version: 1.0.0
  • Package version: 1.0.0
  • Build package: org.openapitools.codegen.languages.GoClientCodegen

Installation

Install the following dependencies:

go get github.com/stretchr/testify/assert
go get golang.org/x/oauth2
go get golang.org/x/net/context

Put the package under your project folder and add the following in import:

import sw "./openapi"

To use a proxy, set the environment variable HTTP_PROXY:

os.Setenv("HTTP_PROXY", "http://proxy_name:proxy_port")

Configuration of Server URL

Default configuration comes with Servers field that contains server objects as defined in the OpenAPI specification.

Select Server Configuration

For using other server than the one defined on index 0 set context value sw.ContextServerIndex of type int.

ctx := context.WithValue(context.Background(), sw.ContextServerIndex, 1)

Templated Server URL

Templated server URL is formatted using default variables from configuration or from context value sw.ContextServerVariables of type map[string]string.

ctx := context.WithValue(context.Background(), sw.ContextServerVariables, map[string]string{
	"basePath": "v2",
})

Note, enum values are always validated and all unused variables are silently ignored.

URLs Configuration per Operation

Each operation can use different server URL defined using OperationServers map in the Configuration. An operation is uniquely identified by "{classname}Service.{nickname}" string. Similar rules for overriding default operation server index and variables applies by using sw.ContextOperationServerIndices and sw.ContextOperationServerVariables context maps.

ctx := context.WithValue(context.Background(), sw.ContextOperationServerIndices, map[string]int{
	"{classname}Service.{nickname}": 2,
})
ctx = context.WithValue(context.Background(), sw.ContextOperationServerVariables, map[string]map[string]string{
	"{classname}Service.{nickname}": {
		"port": "8443",
	},
})

Documentation for API Endpoints

All URIs are relative to https://api.au.sumologic.com/api

Class Method HTTP request Description
AccessKeyManagementApi CreateAccessKey Post /v1/accessKeys Create an access key.
AccessKeyManagementApi DeleteAccessKey Delete /v1/accessKeys/{id} Delete an access key.
AccessKeyManagementApi ListAccessKeys Get /v1/accessKeys List all access keys.
AccessKeyManagementApi ListPersonalAccessKeys Get /v1/accessKeys/personal List personal keys.
AccessKeyManagementApi UpdateAccessKey Put /v1/accessKeys/{id} Update an access key.
AccountManagementApi CreateSubdomain Post /v1/account/subdomain Create account subdomain.
AccountManagementApi DeleteSubdomain Delete /v1/account/subdomain Delete the configured subdomain.
AccountManagementApi GetAccountOwner Get /v1/account/accountOwner Get the owner of an account.
AccountManagementApi GetStatus Get /v1/account/status Get overview of the account status.
AccountManagementApi GetSubdomain Get /v1/account/subdomain Get the configured subdomain.
AccountManagementApi RecoverSubdomains Post /v1/account/subdomain/recover Recover subdomains for a user.
AccountManagementApi UpdateSubdomain Put /v1/account/subdomain Update account subdomain.
AppManagementApi GetApp Get /v1/apps/{uuid} Get an app by UUID.
AppManagementApi GetAsyncInstallStatus Get /v1/apps/install/{jobId}/status App install job status.
AppManagementApi InstallApp Post /v1/apps/{uuid}/install Install an app by UUID.
AppManagementApi ListApps Get /v1/apps List available apps.
ArchiveManagementApi CreateArchiveJob Post /v1/archive/{sourceId}/jobs Create an ingestion job.
ArchiveManagementApi DeleteArchiveJob Delete /v1/archive/{sourceId}/jobs/{id} Delete an ingestion job.
ArchiveManagementApi ListArchiveJobsBySourceId Get /v1/archive/{sourceId}/jobs Get ingestion jobs for an Archive Source.
ArchiveManagementApi ListArchiveJobsCountPerSource Get /v1/archive/jobs/count List ingestion jobs for all Archive Sources.
ConnectionManagementApi CreateConnection Post /v1/connections Create a new connection.
ConnectionManagementApi DeleteConnection Delete /v1/connections/{id} Delete a connection.
ConnectionManagementApi GetConnection Get /v1/connections/{id} Get a connection.
ConnectionManagementApi ListConnections Get /v1/connections Get a list of connections.
ConnectionManagementApi TestConnection Post /v1/connections/test Test a new connection url.
ConnectionManagementApi UpdateConnection Put /v1/connections/{id} Update a connection.
ContentManagementApi AsyncCopyStatus Get /v2/content/{id}/copy/{jobId}/status Content copy job status.
ContentManagementApi BeginAsyncCopy Post /v2/content/{id}/copy Start a content copy job.
ContentManagementApi BeginAsyncDelete Delete /v2/content/{id}/delete Start a content deletion job.
ContentManagementApi BeginAsyncExport Post /v2/content/{id}/export Start a content export job.
ContentManagementApi BeginAsyncImport Post /v2/content/folders/{folderId}/import Start a content import job.
ContentManagementApi GetAsyncDeleteStatus Get /v2/content/{id}/delete/{jobId}/status Content deletion job status.
ContentManagementApi GetAsyncExportResult Get /v2/content/{contentId}/export/{jobId}/result Content export job result.
ContentManagementApi GetAsyncExportStatus Get /v2/content/{contentId}/export/{jobId}/status Content export job status.
ContentManagementApi GetAsyncImportStatus Get /v2/content/folders/{folderId}/import/{jobId}/status Content import job status.
ContentManagementApi GetItemByPath Get /v2/content/path Get content item by path.
ContentManagementApi GetPathById Get /v2/content/{contentId}/path Get path of an item.
ContentManagementApi MoveItem Post /v2/content/{id}/move Move an item.
ContentPermissionsApi AddContentPermissions Put /v2/content/{id}/permissions/add Add permissions to a content item.
ContentPermissionsApi GetContentPermissions Get /v2/content/{id}/permissions Get permissions of a content item
ContentPermissionsApi RemoveContentPermissions Put /v2/content/{id}/permissions/remove Remove permissions from a content item.
DashboardManagementApi CreateDashboard Post /v2/dashboards Create a new dashboard.
DashboardManagementApi DeleteDashboard Delete /v2/dashboards/{id} Delete a dashboard.
DashboardManagementApi GenerateDashboardReport Post /v2/dashboards/reportJobs Start a report job
DashboardManagementApi GetAsyncReportGenerationResult Get /v2/dashboards/reportJobs/{jobId}/result Get report generation job result
DashboardManagementApi GetAsyncReportGenerationStatus Get /v2/dashboards/reportJobs/{jobId}/status Get report generation job status
DashboardManagementApi GetDashboard Get /v2/dashboards/{id} Get a dashboard.
DashboardManagementApi UpdateDashboard Put /v2/dashboards/{id} Update a dashboard.
DynamicParsingRuleManagementApi CreateDynamicParsingRule Post /v1/dynamicParsingRules Create a new dynamic parsing rule.
DynamicParsingRuleManagementApi DeleteDynamicParsingRule Delete /v1/dynamicParsingRules/{id} Delete a dynamic parsing rule.
DynamicParsingRuleManagementApi GetDynamicParsingRule Get /v1/dynamicParsingRules/{id} Get a dynamic parsing rule.
DynamicParsingRuleManagementApi ListDynamicParsingRules Get /v1/dynamicParsingRules Get a list of dynamic parsing rules.
DynamicParsingRuleManagementApi UpdateDynamicParsingRule Put /v1/dynamicParsingRules/{id} Update a dynamic parsing rule.
ExtractionRuleManagementApi CreateExtractionRule Post /v1/extractionRules Create a new field extraction rule.
ExtractionRuleManagementApi DeleteExtractionRule Delete /v1/extractionRules/{id} Delete a field extraction rule.
ExtractionRuleManagementApi GetExtractionRule Get /v1/extractionRules/{id} Get a field extraction rule.
ExtractionRuleManagementApi ListExtractionRules Get /v1/extractionRules Get a list of field extraction rules.
ExtractionRuleManagementApi UpdateExtractionRule Put /v1/extractionRules/{id} Update a field extraction rule.
FieldManagementV1Api CreateField Post /v1/fields Create a new field.
FieldManagementV1Api DeleteField Delete /v1/fields/{id} Delete a custom field.
FieldManagementV1Api DisableField Delete /v1/fields/{id}/disable Disable a custom field.
FieldManagementV1Api EnableField Put /v1/fields/{id}/enable Enable custom field with a specified identifier.
FieldManagementV1Api GetBuiltInField Get /v1/fields/builtin/{id} Get a built-in field.
FieldManagementV1Api GetCustomField Get /v1/fields/{id} Get a custom field.
FieldManagementV1Api GetFieldQuota Get /v1/fields/quota Get capacity information.
FieldManagementV1Api ListBuiltInFields Get /v1/fields/builtin Get a list of built-in fields.
FieldManagementV1Api ListCustomFields Get /v1/fields Get a list of all custom fields.
FieldManagementV1Api ListDroppedFields Get /v1/fields/dropped Get a list of dropped fields.
FolderManagementApi CreateFolder Post /v2/content/folders Create a new folder.
FolderManagementApi GetAdminRecommendedFolderAsync Get /v2/content/folders/adminRecommended Schedule Admin Recommended folder job
FolderManagementApi GetAdminRecommendedFolderAsyncResult Get /v2/content/folders/adminRecommended/{jobId}/result Get Admin Recommended folder job result
FolderManagementApi GetAdminRecommendedFolderAsyncStatus Get /v2/content/folders/adminRecommended/{jobId}/status Get Admin Recommended folder job status
FolderManagementApi GetFolder Get /v2/content/folders/{id} Get a folder.
FolderManagementApi GetGlobalFolderAsync Get /v2/content/folders/global Schedule Global View job
FolderManagementApi GetGlobalFolderAsyncResult Get /v2/content/folders/global/{jobId}/result Get Global View job result
FolderManagementApi GetGlobalFolderAsyncStatus Get /v2/content/folders/global/{jobId}/status Get Global View job status
FolderManagementApi GetPersonalFolder Get /v2/content/folders/personal Get personal folder.
FolderManagementApi UpdateFolder Put /v2/content/folders/{id} Update a folder.
HealthEventsApi ListAllHealthEvents Get /v1/healthEvents Get a list of health events.
HealthEventsApi ListAllHealthEventsForResources Post /v1/healthEvents/resources Health events for specific resources.
IngestBudgetManagementV1Api AssignCollectorToBudget Put /v1/ingestBudgets/{id}/collectors/{collectorId} Assign a Collector to a budget.
IngestBudgetManagementV1Api CreateIngestBudget Post /v1/ingestBudgets Create a new ingest budget.
IngestBudgetManagementV1Api DeleteIngestBudget Delete /v1/ingestBudgets/{id} Delete an ingest budget.
IngestBudgetManagementV1Api GetAssignedCollectors Get /v1/ingestBudgets/{id}/collectors Get a list of Collectors.
IngestBudgetManagementV1Api GetIngestBudget Get /v1/ingestBudgets/{id} Get an ingest budget.
IngestBudgetManagementV1Api ListIngestBudgets Get /v1/ingestBudgets Get a list of ingest budgets.
IngestBudgetManagementV1Api RemoveCollectorFromBudget Delete /v1/ingestBudgets/{id}/collectors/{collectorId} Remove Collector from a budget.
IngestBudgetManagementV1Api ResetUsage Post /v1/ingestBudgets/{id}/usage/reset Reset usage.
IngestBudgetManagementV1Api UpdateIngestBudget Put /v1/ingestBudgets/{id} Update an ingest budget.
IngestBudgetManagementV2Api CreateIngestBudgetV2 Post /v2/ingestBudgets Create a new ingest budget.
IngestBudgetManagementV2Api DeleteIngestBudgetV2 Delete /v2/ingestBudgets/{id} Delete an ingest budget.
IngestBudgetManagementV2Api GetIngestBudgetV2 Get /v2/ingestBudgets/{id} Get an ingest budget.
IngestBudgetManagementV2Api ListIngestBudgetsV2 Get /v2/ingestBudgets Get a list of ingest budgets.
IngestBudgetManagementV2Api ResetUsageV2 Post /v2/ingestBudgets/{id}/usage/reset Reset usage.
IngestBudgetManagementV2Api UpdateIngestBudgetV2 Put /v2/ingestBudgets/{id} Update an ingest budget.
LogSearchesEstimatedUsageApi GetLogSearchEstimatedUsage Post /v1/logSearches/estimatedUsage Gets estimated usage details.
LogSearchesEstimatedUsageApi GetLogSearchEstimatedUsageByTier Post /v1/logSearches/estimatedUsageByTier Gets Tier Wise estimated usage details.
LookupManagementApi CreateTable Post /v1/lookupTables Create a lookup table.
LookupManagementApi DeleteTable Delete /v1/lookupTables/{id} Delete a lookup table.
LookupManagementApi DeleteTableRow Put /v1/lookupTables/{id}/deleteTableRow Delete a lookup table row.
LookupManagementApi LookupTableById Get /v1/lookupTables/{id} Get a lookup table.
LookupManagementApi RequestJobStatus Get /v1/lookupTables/jobs/{jobId}/status Get the status of an async job.
LookupManagementApi TruncateTable Post /v1/lookupTables/{id}/truncate Empty a lookup table.
LookupManagementApi UpdateTable Put /v1/lookupTables/{id} Edit a lookup table.
LookupManagementApi UpdateTableRow Put /v1/lookupTables/{id}/row Insert or Update a lookup table row.
LookupManagementApi UploadFile Post /v1/lookupTables/{id}/upload Upload a CSV file.
MetricsQueryApi RunMetricsQueries Post /v1/metricsQueries Run metrics queries
MetricsSearchesManagementApi CreateMetricsSearch Post /v1/metricsSearches Save a metrics search.
MetricsSearchesManagementApi DeleteMetricsSearch Delete /v1/metricsSearches/{id} Deletes a metrics search.
MetricsSearchesManagementApi GetMetricsSearch Get /v1/metricsSearches/{id} Get a metrics search.
MetricsSearchesManagementApi UpdateMetricsSearch Put /v1/metricsSearches/{id} Updates a metrics search.
MonitorsLibraryManagementApi DisableMonitorByIds Put /v1/monitors/disable Disable monitors.
MonitorsLibraryManagementApi GetMonitorUsageInfo Get /v1/monitors/usageInfo Usage info of monitors.
MonitorsLibraryManagementApi GetMonitorsFullPath Get /v1/monitors/{id}/path Get the path of a monitor or folder.
MonitorsLibraryManagementApi GetMonitorsLibraryRoot Get /v1/monitors/root Get the root monitors folder.
MonitorsLibraryManagementApi MonitorsCopy Post /v1/monitors/{id}/copy Copy a monitor or folder.
MonitorsLibraryManagementApi MonitorsCreate Post /v1/monitors Create a monitor or folder.
MonitorsLibraryManagementApi MonitorsDeleteById Delete /v1/monitors/{id} Delete a monitor or folder.
MonitorsLibraryManagementApi MonitorsDeleteByIds Delete /v1/monitors Bulk delete a monitor or folder.
MonitorsLibraryManagementApi MonitorsExportItem Get /v1/monitors/{id}/export Export a monitor or folder.
MonitorsLibraryManagementApi MonitorsGetByPath Get /v1/monitors/path Read a monitor or folder by its path.
MonitorsLibraryManagementApi MonitorsImportItem Post /v1/monitors/{parentId}/import Import a monitor or folder.
MonitorsLibraryManagementApi MonitorsMove Post /v1/monitors/{id}/move Move a monitor or folder.
MonitorsLibraryManagementApi MonitorsReadById Get /v1/monitors/{id} Get a monitor or folder.
MonitorsLibraryManagementApi MonitorsReadByIds Get /v1/monitors Bulk read a monitor or folder.
MonitorsLibraryManagementApi MonitorsSearch Get /v1/monitors/search Search for a monitor or folder.
MonitorsLibraryManagementApi MonitorsUpdateById Put /v1/monitors/{id} Update a monitor or folder.
PartitionManagementApi CancelRetentionUpdate Post /v1/partitions/{id}/cancelRetentionUpdate Cancel a retention update for a partition
PartitionManagementApi CreatePartition Post /v1/partitions Create a new partition.
PartitionManagementApi DecommissionPartition Post /v1/partitions/{id}/decommission Decommission a partition.
PartitionManagementApi GetPartition Get /v1/partitions/{id} Get a partition.
PartitionManagementApi ListPartitions Get /v1/partitions Get a list of partitions.
PartitionManagementApi UpdatePartition Put /v1/partitions/{id} Update a partition.
PasswordPolicyApi GetPasswordPolicy Get /v1/passwordPolicy Get the current password policy.
PasswordPolicyApi SetPasswordPolicy Put /v1/passwordPolicy Update password policy.
PoliciesManagementApi GetAuditPolicy Get /v1/policies/audit Get Audit policy.
PoliciesManagementApi GetDataAccessLevelPolicy Get /v1/policies/dataAccessLevel Get Data Access Level policy.
PoliciesManagementApi GetMaxUserSessionTimeoutPolicy Get /v1/policies/maxUserSessionTimeout Get Max User Session Timeout policy.
PoliciesManagementApi GetSearchAuditPolicy Get /v1/policies/searchAudit Get Search Audit policy.
PoliciesManagementApi GetShareDashboardsOutsideOrganizationPolicy Get /v1/policies/shareDashboardsOutsideOrganization Get Share Dashboards Outside Organization policy.
PoliciesManagementApi GetUserConcurrentSessionsLimitPolicy Get /v1/policies/userConcurrentSessionsLimit Get User Concurrent Sessions Limit policy.
PoliciesManagementApi SetAuditPolicy Put /v1/policies/audit Set Audit policy.
PoliciesManagementApi SetDataAccessLevelPolicy Put /v1/policies/dataAccessLevel Set Data Access Level policy.
PoliciesManagementApi SetMaxUserSessionTimeoutPolicy Put /v1/policies/maxUserSessionTimeout Set Max User Session Timeout policy.
PoliciesManagementApi SetSearchAuditPolicy Put /v1/policies/searchAudit Set Search Audit policy.
PoliciesManagementApi SetShareDashboardsOutsideOrganizationPolicy Put /v1/policies/shareDashboardsOutsideOrganization Set Share Dashboards Outside Organization policy.
PoliciesManagementApi SetUserConcurrentSessionsLimitPolicy Put /v1/policies/userConcurrentSessionsLimit Set User Concurrent Sessions Limit policy.
RoleManagementApi AssignRoleToUser Put /v1/roles/{roleId}/users/{userId} Assign a role to a user.
RoleManagementApi CreateRole Post /v1/roles Create a new role.
RoleManagementApi DeleteRole Delete /v1/roles/{id} Delete a role.
RoleManagementApi GetRole Get /v1/roles/{id} Get a role.
RoleManagementApi ListRoles Get /v1/roles Get a list of roles.
RoleManagementApi RemoveRoleFromUser Delete /v1/roles/{roleId}/users/{userId} Remove role from a user.
RoleManagementApi UpdateRole Put /v1/roles/{id} Update a role.
SamlConfigurationManagementApi CreateAllowlistedUser Post /v1/saml/allowlistedUsers/{userId} Allowlist a user.
SamlConfigurationManagementApi CreateIdentityProvider Post /v1/saml/identityProviders Create a new SAML configuration.
SamlConfigurationManagementApi DeleteAllowlistedUser Delete /v1/saml/allowlistedUsers/{userId} Remove an allowlisted user.
SamlConfigurationManagementApi DeleteIdentityProvider Delete /v1/saml/identityProviders/{id} Delete a SAML configuration.
SamlConfigurationManagementApi DisableSamlLockdown Post /v1/saml/lockdown/disable Disable SAML lockdown.
SamlConfigurationManagementApi EnableSamlLockdown Post /v1/saml/lockdown/enable Require SAML for sign-in.
SamlConfigurationManagementApi GetAllowlistedUsers Get /v1/saml/allowlistedUsers Get list of allowlisted users.
SamlConfigurationManagementApi GetIdentityProviders Get /v1/saml/identityProviders Get a list of SAML configurations.
SamlConfigurationManagementApi UpdateIdentityProvider Put /v1/saml/identityProviders/{id} Update a SAML configuration.
ScheduledViewManagementApi CreateScheduledView Post /v1/scheduledViews Create a new scheduled view.
ScheduledViewManagementApi DisableScheduledView Delete /v1/scheduledViews/{id}/disable Disable a scheduled view.
ScheduledViewManagementApi GetScheduledView Get /v1/scheduledViews/{id} Get a scheduled view.
ScheduledViewManagementApi ListScheduledViews Get /v1/scheduledViews Get a list of scheduled views.
ScheduledViewManagementApi PauseScheduledView Post /v1/scheduledViews/{id}/pause Pause a scheduled view.
ScheduledViewManagementApi StartScheduledView Post /v1/scheduledViews/{id}/start Start a scheduled view.
ScheduledViewManagementApi UpdateScheduledView Put /v1/scheduledViews/{id} Update a scheduled view.
ServiceAllowlistManagementApi AddAllowlistedCidrs Post /v1/serviceAllowlist/addresses/add Allowlist CIDRs/IP addresses.
ServiceAllowlistManagementApi DeleteAllowlistedCidrs Post /v1/serviceAllowlist/addresses/remove Remove allowlisted CIDRs/IP addresses.
ServiceAllowlistManagementApi DisableAllowlisting Post /v1/serviceAllowlist/disable Disable service allowlisting.
ServiceAllowlistManagementApi EnableAllowlisting Post /v1/serviceAllowlist/enable Enable service allowlisting.
ServiceAllowlistManagementApi GetAllowlistingStatus Get /v1/serviceAllowlist/status Get the allowlisting status.
ServiceAllowlistManagementApi ListAllowlistedCidrs Get /v1/serviceAllowlist/addresses List all allowlisted CIDRs/IP addresses.
TokensLibraryManagementApi CreateToken Post /v1/tokens Create a token.
TokensLibraryManagementApi DeleteToken Delete /v1/tokens/{id} Delete a token.
TokensLibraryManagementApi GetToken Get /v1/tokens/{id} Get a token.
TokensLibraryManagementApi ListTokens Get /v1/tokens Get a list of tokens.
TokensLibraryManagementApi UpdateToken Put /v1/tokens/{id} Update a token.
TransformationRuleManagementApi CreateRule Post /v1/transformationRules Create a new transformation rule.
TransformationRuleManagementApi DeleteRule Delete /v1/transformationRules/{id} Delete a transformation rule.
TransformationRuleManagementApi GetTransformationRule Get /v1/transformationRules/{id} Get a transformation rule.
TransformationRuleManagementApi GetTransformationRules Get /v1/transformationRules Get a list of transformation rules.
TransformationRuleManagementApi UpdateTransformationRule Put /v1/transformationRules/{id} Update a transformation rule.
UserManagementApi CreateUser Post /v1/users Create a new user.
UserManagementApi DeleteUser Delete /v1/users/{id} Delete a user.
UserManagementApi DisableMfa Put /v1/users/{id}/mfa/disable Disable MFA for user.
UserManagementApi GetUser Get /v1/users/{id} Get a user.
UserManagementApi ListUsers Get /v1/users Get a list of users.
UserManagementApi RequestChangeEmail Post /v1/users/{id}/email/requestChange Change email address.
UserManagementApi ResetPassword Post /v1/users/{id}/password/reset Reset password.
UserManagementApi UnlockUser Post /v1/users/{id}/unlock Unlock a user.
UserManagementApi UpdateUser Put /v1/users/{id} Update a user.

Documentation For Models

Documentation For Authorization

basicAuth

  • Type: HTTP basic authentication

Example

auth := context.WithValue(context.Background(), sw.ContextBasicAuth, sw.BasicAuth{
    UserName: "username",
    Password: "password",
})
r, err := client.Service.Operation(auth, args)

Documentation for Utility Methods

Due to the fact that model structure members are all pointers, this package contains a number of utility functions to easily obtain pointers to values of basic types. Each of these functions takes a value of the given basic type and returns a pointer to it:

  • PtrBool
  • PtrInt
  • PtrInt32
  • PtrInt64
  • PtrFloat
  • PtrFloat32
  • PtrFloat64
  • PtrString
  • PtrTime

Author

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages