> For the complete documentation index, see [llms.txt](https://docs.panther.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.panther.com/ko/panther/api/rest/log-sources/s3-sources.md).

# S3 소스

## 개요

상호 작용하려면 다음 API 작업을 사용하세요 [S3 소스](/ko/data-onboarding/data-transports/aws/s3.md) 를 Panther에서.

## 필수 권한

* 자체 호스팅 `GET` 작업을 수행하려면, API 토큰에 다음이 있어야 합니다 `로그 소스 보기` 권한.
* 자체 호스팅 `POST`, `PUT`, 그리고 `DELETE` 작업을 수행하려면, API 토큰에 다음이 있어야 합니다 `로그 소스 관리` 권한.

## POST /log-sources/s3

> create s3 source

```json
{"openapi":"3.0.3","info":{"title":"Panther REST API","version":"1.0"},"tags":[{"name":"s3 source","description":"The S3 source API handles all operations for AWS S3 log sources"}],"servers":[{"url":"https://{api_host}","variables":{"api_host":{"default":"your-api-host"}}}],"security":[{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","name":"X-API-Key","in":"header"}},"schemas":{"S3SourceAPI.CreateS3Source":{"type":"object","properties":{"awsAccountId":{"type":"string","description":"The 12-digit AWS account ID where the S3 bucket resides"},"integrationLabel":{"type":"string","description":"The integration label (name)"},"kmsKey":{"type":"string","description":"KMS key ARN for server-side encryption. Omit if the bucket is not KMS-encrypted."},"logProcessingRole":{"type":"string","description":"The IAM role ARN that Panther assumes to read from the S3 bucket"},"logStreamType":{"type":"string","description":"The log stream type. Supported: Auto, JSON, JsonArray, Lines, XML, CloudWatchLogs","enum":["Auto","JSON","JsonArray","Lines","XML","CloudWatchLogs"]},"logStreamTypeOptions":{"$ref":"#/components/schemas/S3SourceAPI.S3LogStreamTypeOptions"},"managedBucketNotifications":{"type":"boolean","description":"Whether Panther should configure the S3 bucket notifications automatically"},"s3Bucket":{"type":"string","description":"The S3 bucket name"},"s3PrefixLogTypes":{"type":"array","items":{"$ref":"#/components/schemas/S3SourceAPI.PrefixLogTypesMapping"},"description":"Prefix-based log type mappings for parsing ingested data"}},"required":["awsAccountId","s3Bucket","integrationLabel","s3PrefixLogTypes","managedBucketNotifications","logProcessingRole","logStreamType"]},"S3SourceAPI.S3LogStreamTypeOptions":{"type":"object","properties":{"jsonArrayEnvelopeField":{"type":"string","description":"Path to the JSON array field to extract records from. Only applicable when logStreamType is JsonArray. Omit if the input is already a top-level array."},"retainEnvelopeFields":{"type":"boolean","description":"Preserve CloudWatch Logs envelope metadata (accountId, logGroup, subscriptionFilters) in a p_header column. Only applicable when logStreamType is CloudWatchLogs."},"xmlRootElement":{"type":"string","description":"Root element wrapping XML events. Only applicable when logStreamType is XML. Omit if events are not enclosed in a root element."}}},"S3SourceAPI.PrefixLogTypesMapping":{"type":"object","properties":{"excludedPrefixes":{"type":"array","items":{"type":"string"},"description":"Prefixes to exclude from matching. Use '*' as a wildcard for dynamic path segments."},"logTypes":{"type":"array","items":{"type":"string"},"description":"The log types (schemas) to apply for this prefix"},"prefix":{"type":"string","description":"S3 prefix to match. Leave empty to match all objects in the bucket."}}},"S3SourceAPI.S3Source":{"type":"object","properties":{"awsAccountId":{"type":"string","description":"The AWS account ID where the S3 bucket resides"},"integrationId":{"type":"string","description":"The unique ID of the S3 log source"},"integrationLabel":{"type":"string","description":"The integration label (name)"},"kmsKey":{"type":"string","description":"KMS key ARN for server-side encryption. Omit if the bucket is not KMS-encrypted."},"logProcessingRole":{"type":"string","description":"The IAM role ARN that Panther assumes to read from the S3 bucket"},"logStreamType":{"type":"string","description":"The log stream type. Supported: Auto, JSON, JsonArray, Lines, XML, CloudWatchLogs","enum":["Auto","JSON","JsonArray","Lines","XML","CloudWatchLogs"]},"logStreamTypeOptions":{"$ref":"#/components/schemas/S3SourceAPI.S3LogStreamTypeOptions"},"managedBucketNotifications":{"type":"boolean","description":"Whether Panther should configure the S3 bucket notifications automatically"},"s3Bucket":{"type":"string","description":"The S3 bucket name"},"s3PrefixLogTypes":{"type":"array","items":{"$ref":"#/components/schemas/S3SourceAPI.PrefixLogTypesMapping"},"description":"Prefix-based log type mappings for parsing ingested data"}}},"S3SourceAPI.BadRequestError":{"type":"object","properties":{"message":{"type":"string"}},"required":["message"]},"S3SourceAPI.ExistsError":{"type":"object","properties":{"message":{"type":"string"}},"required":["message"]},"S3SourceAPI.ServiceError":{"type":"object","properties":{"message":{"type":"string"}},"required":["message"]}}},"paths":{"/log-sources/s3":{"post":{"tags":["s3 source"],"summary":"create s3 source","operationId":"s3 source#create","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/S3SourceAPI.CreateS3Source"}}}},"responses":{"201":{"description":"Created response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/S3SourceAPI.S3Source"}}}},"400":{"description":"bad_request: Bad Request response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/S3SourceAPI.BadRequestError"}}}},"409":{"description":"exists: Conflict response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/S3SourceAPI.ExistsError"}}}},"500":{"description":"service: Internal Server Error response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/S3SourceAPI.ServiceError"}}}}}}}}}
```

## GET /log-sources/s3/{id}

> get s3 source

```json
{"openapi":"3.0.3","info":{"title":"Panther REST API","version":"1.0"},"tags":[{"name":"s3 source","description":"The S3 source API handles all operations for AWS S3 log sources"}],"servers":[{"url":"https://{api_host}","variables":{"api_host":{"default":"your-api-host"}}}],"security":[{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","name":"X-API-Key","in":"header"}},"schemas":{"S3SourceAPI.S3Source":{"type":"object","properties":{"awsAccountId":{"type":"string","description":"The AWS account ID where the S3 bucket resides"},"integrationId":{"type":"string","description":"The unique ID of the S3 log source"},"integrationLabel":{"type":"string","description":"The integration label (name)"},"kmsKey":{"type":"string","description":"KMS key ARN for server-side encryption. Omit if the bucket is not KMS-encrypted."},"logProcessingRole":{"type":"string","description":"The IAM role ARN that Panther assumes to read from the S3 bucket"},"logStreamType":{"type":"string","description":"The log stream type. Supported: Auto, JSON, JsonArray, Lines, XML, CloudWatchLogs","enum":["Auto","JSON","JsonArray","Lines","XML","CloudWatchLogs"]},"logStreamTypeOptions":{"$ref":"#/components/schemas/S3SourceAPI.S3LogStreamTypeOptions"},"managedBucketNotifications":{"type":"boolean","description":"Whether Panther should configure the S3 bucket notifications automatically"},"s3Bucket":{"type":"string","description":"The S3 bucket name"},"s3PrefixLogTypes":{"type":"array","items":{"$ref":"#/components/schemas/S3SourceAPI.PrefixLogTypesMapping"},"description":"Prefix-based log type mappings for parsing ingested data"}}},"S3SourceAPI.S3LogStreamTypeOptions":{"type":"object","properties":{"jsonArrayEnvelopeField":{"type":"string","description":"Path to the JSON array field to extract records from. Only applicable when logStreamType is JsonArray. Omit if the input is already a top-level array."},"retainEnvelopeFields":{"type":"boolean","description":"Preserve CloudWatch Logs envelope metadata (accountId, logGroup, subscriptionFilters) in a p_header column. Only applicable when logStreamType is CloudWatchLogs."},"xmlRootElement":{"type":"string","description":"Root element wrapping XML events. Only applicable when logStreamType is XML. Omit if events are not enclosed in a root element."}}},"S3SourceAPI.PrefixLogTypesMapping":{"type":"object","properties":{"excludedPrefixes":{"type":"array","items":{"type":"string"},"description":"Prefixes to exclude from matching. Use '*' as a wildcard for dynamic path segments."},"logTypes":{"type":"array","items":{"type":"string"},"description":"The log types (schemas) to apply for this prefix"},"prefix":{"type":"string","description":"S3 prefix to match. Leave empty to match all objects in the bucket."}}},"S3SourceAPI.BadRequestError":{"type":"object","properties":{"message":{"type":"string"}},"required":["message"]},"S3SourceAPI.NotFoundError":{"type":"object","properties":{"message":{"type":"string"}},"required":["message"]},"S3SourceAPI.ServiceError":{"type":"object","properties":{"message":{"type":"string"}},"required":["message"]}}},"paths":{"/log-sources/s3/{id}":{"get":{"tags":["s3 source"],"summary":"get s3 source","operationId":"s3 source#get","parameters":[{"name":"id","in":"path","description":"ID of the S3 source to fetch","required":true,"schema":{"type":"string","description":"ID of the S3 source to fetch"}}],"responses":{"200":{"description":"OK response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/S3SourceAPI.S3Source"}}}},"400":{"description":"bad_request: Bad Request response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/S3SourceAPI.BadRequestError"}}}},"404":{"description":"not_found: Not Found response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/S3SourceAPI.NotFoundError"}}}},"500":{"description":"service: Internal Server Error response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/S3SourceAPI.ServiceError"}}}}}}}}}
```

## PUT /log-sources/s3/{id}

> put s3 source

```json
{"openapi":"3.0.3","info":{"title":"Panther REST API","version":"1.0"},"tags":[{"name":"s3 source","description":"The S3 source API handles all operations for AWS S3 log sources"}],"servers":[{"url":"https://{api_host}","variables":{"api_host":{"default":"your-api-host"}}}],"security":[{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","name":"X-API-Key","in":"header"}},"schemas":{"S3SourceAPI.ModifyS3Source":{"type":"object","properties":{"integrationLabel":{"type":"string","description":"The integration label (name)"},"kmsKey":{"type":"string","description":"KMS key ARN for server-side encryption. Omit if the bucket is not KMS-encrypted."},"logProcessingRole":{"type":"string","description":"The IAM role ARN that Panther assumes to read from the S3 bucket"},"logStreamType":{"type":"string","description":"The log stream type. Supported: Auto, JSON, JsonArray, Lines, XML, CloudWatchLogs","enum":["Auto","JSON","JsonArray","Lines","XML","CloudWatchLogs"]},"logStreamTypeOptions":{"$ref":"#/components/schemas/S3SourceAPI.S3LogStreamTypeOptions"},"managedBucketNotifications":{"type":"boolean","description":"Whether Panther should configure the S3 bucket notifications automatically"},"s3PrefixLogTypes":{"type":"array","items":{"$ref":"#/components/schemas/S3SourceAPI.PrefixLogTypesMapping"},"description":"Prefix-based log type mappings for parsing ingested data"}},"required":["integrationLabel","s3PrefixLogTypes","managedBucketNotifications","logProcessingRole","logStreamType"]},"S3SourceAPI.S3LogStreamTypeOptions":{"type":"object","properties":{"jsonArrayEnvelopeField":{"type":"string","description":"Path to the JSON array field to extract records from. Only applicable when logStreamType is JsonArray. Omit if the input is already a top-level array."},"retainEnvelopeFields":{"type":"boolean","description":"Preserve CloudWatch Logs envelope metadata (accountId, logGroup, subscriptionFilters) in a p_header column. Only applicable when logStreamType is CloudWatchLogs."},"xmlRootElement":{"type":"string","description":"Root element wrapping XML events. Only applicable when logStreamType is XML. Omit if events are not enclosed in a root element."}}},"S3SourceAPI.PrefixLogTypesMapping":{"type":"object","properties":{"excludedPrefixes":{"type":"array","items":{"type":"string"},"description":"Prefixes to exclude from matching. Use '*' as a wildcard for dynamic path segments."},"logTypes":{"type":"array","items":{"type":"string"},"description":"The log types (schemas) to apply for this prefix"},"prefix":{"type":"string","description":"S3 prefix to match. Leave empty to match all objects in the bucket."}}},"S3SourceAPI.S3Source":{"type":"object","properties":{"awsAccountId":{"type":"string","description":"The AWS account ID where the S3 bucket resides"},"integrationId":{"type":"string","description":"The unique ID of the S3 log source"},"integrationLabel":{"type":"string","description":"The integration label (name)"},"kmsKey":{"type":"string","description":"KMS key ARN for server-side encryption. Omit if the bucket is not KMS-encrypted."},"logProcessingRole":{"type":"string","description":"The IAM role ARN that Panther assumes to read from the S3 bucket"},"logStreamType":{"type":"string","description":"The log stream type. Supported: Auto, JSON, JsonArray, Lines, XML, CloudWatchLogs","enum":["Auto","JSON","JsonArray","Lines","XML","CloudWatchLogs"]},"logStreamTypeOptions":{"$ref":"#/components/schemas/S3SourceAPI.S3LogStreamTypeOptions"},"managedBucketNotifications":{"type":"boolean","description":"Whether Panther should configure the S3 bucket notifications automatically"},"s3Bucket":{"type":"string","description":"The S3 bucket name"},"s3PrefixLogTypes":{"type":"array","items":{"$ref":"#/components/schemas/S3SourceAPI.PrefixLogTypesMapping"},"description":"Prefix-based log type mappings for parsing ingested data"}}},"S3SourceAPI.BadRequestError":{"type":"object","properties":{"message":{"type":"string"}},"required":["message"]},"S3SourceAPI.NotFoundError":{"type":"object","properties":{"message":{"type":"string"}},"required":["message"]},"S3SourceAPI.ExistsError":{"type":"object","properties":{"message":{"type":"string"}},"required":["message"]},"S3SourceAPI.ServiceError":{"type":"object","properties":{"message":{"type":"string"}},"required":["message"]}}},"paths":{"/log-sources/s3/{id}":{"put":{"tags":["s3 source"],"summary":"put s3 source","operationId":"s3 source#put","parameters":[{"name":"id","in":"path","description":"ID of the S3 source to update","required":true,"schema":{"type":"string","description":"ID of the S3 source to update"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/S3SourceAPI.ModifyS3Source"}}}},"responses":{"200":{"description":"OK response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/S3SourceAPI.S3Source"}}}},"400":{"description":"bad_request: Bad Request response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/S3SourceAPI.BadRequestError"}}}},"404":{"description":"not_found: Not Found response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/S3SourceAPI.NotFoundError"}}}},"409":{"description":"exists: Conflict response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/S3SourceAPI.ExistsError"}}}},"500":{"description":"service: Internal Server Error response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/S3SourceAPI.ServiceError"}}}}}}}}}
```

## DELETE /log-sources/s3/{id}

> delete s3 source

```json
{"openapi":"3.0.3","info":{"title":"Panther REST API","version":"1.0"},"tags":[{"name":"s3 source","description":"The S3 source API handles all operations for AWS S3 log sources"}],"servers":[{"url":"https://{api_host}","variables":{"api_host":{"default":"your-api-host"}}}],"security":[{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","name":"X-API-Key","in":"header"}},"schemas":{"S3SourceAPI.BadRequestError":{"type":"object","properties":{"message":{"type":"string"}},"required":["message"]},"S3SourceAPI.ServiceError":{"type":"object","properties":{"message":{"type":"string"}},"required":["message"]}}},"paths":{"/log-sources/s3/{id}":{"delete":{"tags":["s3 source"],"summary":"delete s3 source","operationId":"s3 source#delete","parameters":[{"name":"id","in":"path","description":"ID of the S3 source to delete","required":true,"schema":{"type":"string","description":"ID of the S3 source to delete"}}],"responses":{"204":{"description":"No Content response."},"400":{"description":"bad_request: Bad Request response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/S3SourceAPI.BadRequestError"}}}},"500":{"description":"service: Internal Server Error response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/S3SourceAPI.ServiceError"}}}}}}}}}
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.panther.com/ko/panther/api/rest/log-sources/s3-sources.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
