Skip to main content

Falcon cross-origin middleware

Project description

falcon-crossorigin codecov

A simple Falcon module for Cross-Origin Resource Sharing (CORS).

Install

pip install falcon-crossorigin

Usage

import falcon
from falcon_crossorigin import CrossOrigin

cross_origin = CrossOrigin(
    allow_origins="https://app.example.com",
    allow_methods="GET,POST",
    allow_headers="Pragma,Expires,Cache-Control",
    allow_credentials=True,
    expose_headers="Link",
    max_age=3600,
)

api = falcon.API(middleware=[cross_origin])

Credits

Port of Echo's CORS middleware.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

falcon-crossorigin-1.0.0.tar.gz (5.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

falcon_crossorigin-1.0.0-py3-none-any.whl (4.9 kB view details)

Uploaded Python 3

File details

Details for the file falcon-crossorigin-1.0.0.tar.gz.

File metadata

  • Download URL: falcon-crossorigin-1.0.0.tar.gz
  • Upload date:
  • Size: 5.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.11.5

File hashes

Hashes for falcon-crossorigin-1.0.0.tar.gz
Algorithm Hash digest
SHA256 ca4d94c07d655b699809e1864e47102f83283d0255699abe2ed5e88b5f3bb766
MD5 8d6514fdec9bb82a74bf682395b26203
BLAKE2b-256 5b7ef657474083782124c723b73a26e74a1ff59c0c10f3a828a1acd068115d47

See more details on using hashes here.

File details

Details for the file falcon_crossorigin-1.0.0-py3-none-any.whl.

File metadata

File hashes

Hashes for falcon_crossorigin-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 587aed72e5df50084a23d6b1c516bdd6fdd6e04ec845c243171081413ffc70cb
MD5 f8c8824d45cea6cb84951af78b712db9
BLAKE2b-256 7b8713121c0c8655b48997a9b2186f996772d8dc3361b57e6db548d6776475d4

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page