Skip to main content

Create a new S3 bucket connector

POST 

https://api.logz.io/v1/log-shipping/s3-buckets

Establishes a new connection of the Logz.io fetcher to an AWS S3 bucket. As a result, logs from your AWS resource will begin shipping to the connected Logz.io account via an AWS S3 bucket.

Logs will be parsed using the Logz.io custom parsing pipeline for the resource.

Please ensure to change the region in the URL to match your account's region.

Request

Body

    accessKey string

    AWS S3 bucket access key

    secretKey string

    AWS S3 bucket secret key

    arn string

    Amazon Resource Name (ARN) to uniquely identify the S3 bucket. To generate a new ARN, create a new IAM Role in your AWS admin console.

    bucket stringrequired

    AWS S3 bucket name

    prefix string

    Prefix of the AWS S3 bucket

    active boolean

    Default value: true

    If true, the S3 bucket connector is active and logs are being shipped to Logz.io. If false, the connector is disabled.

    addS3ObjectKeyAsLogField boolean

    Default value: false

    If true, enriches logs with a new field detailing the S3 object key.

    region stringrequired

    Possible values: [US_EAST_1, US_EAST_2, US_WEST_1, US_WEST_2, EU_WEST_1, EU_WEST_2, EU_WEST_3, EU_CENTRAL_1, AP_NORTHEAST_1, AP_NORTHEAST_2, AP_SOUTHEAST_1, AP_SOUTHEAST_2, SA_EAST_1, AP_SOUTH_1, CA_CENTRAL_1]

    Specify one supported AWS region.

    logsType stringrequired

    Possible values: [elb, vpcflow, S3Access, cloudfront]

    Specify the log type you will be sending to Logz.io. As a result, Logz.io will apply the appropriate parsing pipeline. Learn more about parsing options supported by Logz.io.

Responses

successful operation

Authorization: X-API-TOKEN

name: X-API-TOKENtype: apiKeydescription: You can manage your API tokens from the [Logz.io API tokens](https://app.logz.io/#/dashboard/settings/manage-tokens/api) page.

API tokens are account-specific. You will need to be logged into the relevant Log Management or SIEM account to view the API tokens associated with it.

To manage your API tokens, log into the relevant account in your Logz.io platform, click the gear in the top-right menu, and select [**Tools > Manage tokens > API tokens**](https://app.logz.io/#/dashboard/settings/manage-tokens/api).

It's important to keep your tokens secure. API tokens carry privileges to make changes to users and accounts, so if you believe an API token has been compromised, delete it, and replace it with a new token in your integrations.in: header
curl -L -X POST 'https://api.logz.io/v1/log-shipping/s3-buckets' \
-H 'Content-Type: application/json' \
-H 'X-API-TOKEN: <API_KEY_VALUE>' \
--data-raw '{
"accessKey": "ee07df5801500745419c6dff",
"secretKey": "506d891fe2163a511b450eddc3279539f6",
"arn": "string",
"bucket": "AWS bucket",
"prefix": "AWSLogs/7364988021587/myprefix",
"active": true,
"addS3ObjectKeyAsLogField": true,
"region": "US_EAST_1",
"logsType": "elb"
}'
Request Collapse all
Base URL
https://api.logz.io
Auth
Body
{
  "accessKey": "ee07df5801500745419c6dff",
  "secretKey": "506d891fe2163a511b450eddc3279539f6",
  "arn": "string",
  "bucket": "AWS bucket",
  "prefix": "AWSLogs/7364988021587/myprefix",
  "active": true,
  "addS3ObjectKeyAsLogField": true,
  "region": "US_EAST_1",
  "logsType": "elb"
}