code-chat-br / whatsapp-api

CodeChat - WhatsApp Api
https://docs.codechat.dev
Apache License 2.0
566 stars 236 forks source link

how to set CORS in v1.3.0 #100

Closed eelco2k closed 7 months ago

eelco2k commented 7 months ago

The .env config for setting CORS is not available in 1.3.0 i did have it in version v1.2.6

in my env.yml file:


# Choose the server type for the application
SERVER:
  TYPE: http # https
  PORT: 8086 # 443

CORS:
  ORIGIN:
    - '*'
    # - yourdomain.com
  METHODS:
    - POST
    - GET
    - PUT
    - DELETE
  CREDENTIALS: true

i could set the CORS ORIGIN

jrCleber commented 7 months ago

It is more appropriate to perform color settings in the reverse proxy.