---
title: "Edit Cross-Origin Resource Sharing (CORS) settings"
method: POST
path: "/api/v1/edit/cors"
tags: ["Cross-Origin Resource Sharing (CORS)"]
---

# Edit Cross-Origin Resource Sharing (CORS) settings

`POST /api/v1/edit/cors`

This endpoint allows you to manage Cross-Origin Resource Sharing (CORS) settings for the API. CORS is a security feature implemented by web browsers to prevent unauthorized cross-origin requests. By editing the CORS settings, you can specify which domains and which methods are permitted to access the API resources from outside the mailcow domain.

## Request body

- object
  - `attr` object
    - `allowed_origins` string[]
    - `allowed_methods` string[]

## Response `200`

OK

## Other responses

- `401` — Unauthorized

## Changes

- **2023-07-27** `2c702c022060` — 1 info
  - endpoint added
- **2020-06-07** `47523aca063a` — 1 breaking
  - api path removed without deprecation

[Change history](https://skmtc.dev/mailcow/apis/mailcow-api/changes/api/v1/edit/cors/post.md)

---

[API](https://skmtc.dev/mailcow/apis/mailcow-api.md) · [All operations](https://skmtc.dev/mailcow/apis/mailcow-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/mailcow/mailcow-api/revisions/ae01d1d7886a/schema)
