# Delete S3 Credentials

<Heading
  as={"h1"}
  className={"openapi__heading"}
  children={"Delete S3 Credentials"}
>
</Heading>

<MethodEndpoint
  method={"delete"}
  path={"/api/v1/infrastructure/file_stores/{credentials_id}"}
  context={"endpoint"}
>
  
</MethodEndpoint>

Delete credentials to your own S3 bucket.

<Heading
  id={"request"}
  as={"h2"}
  className={"openapi-tabs__heading"}
  children={"Request"}
>
</Heading>

<ParamsDetails
  parameters={[{"description":"A unique identifier of the credentials you want to delete. Use the [List Available OpenSearch Credentials](https://docs.cloud.deepset.ai/reference/list_available_opensearch_credentials_api_v1_infrastructure_document_stores_get) endpoint to check the ID.","in":"path","name":"credentials_id","required":true,"schema":{"description":"A unique identifier of the credentials you want to delete. Use the [List Available OpenSearch Credentials](https://docs.cloud.deepset.ai/reference/list_available_opensearch_credentials_api_v1_infrastructure_document_stores_get) endpoint to check the ID.","format":"uuid","title":"Credentials ID","type":"string"}}]}
>
  
</ParamsDetails>

<RequestSchema
  title={"Body"}
  body={undefined}
>
  
</RequestSchema>

<StatusCodes
  id={undefined}
  label={undefined}
  responses={{"204":{"description":"Credentials to your own S3 bucket deleted."},"400":{"description":"We couldn't delete the specified S3 credentials because they are currently in use. Delete all workspaces which use these credentials and try again."},"404":{"description":"We couldn't find the specified S3 bucket credentials. Use the endpoint 'list_available_s3_buckets' to check the S3 bucket credentials that exist in your organization."},"422":{"content":{"application/json":{"schema":{"properties":{"detail":{"items":{"properties":{"ctx":{"title":"Context","type":"object"},"input":{"title":"Input"},"loc":{"items":{"anyOf":[{"type":"string"},{"type":"integer"}]},"title":"Location","type":"array"},"msg":{"title":"Message","type":"string"},"type":{"title":"Error Type","type":"string"}},"required":["loc","msg","type"],"title":"ValidationError","type":"object"},"title":"Detail","type":"array"}},"title":"HTTPValidationError","type":"object"}}},"description":"Validation Error"}}}
>
  
</StatusCodes>
