Manage Environments in Create React App

My API tests pass, but when I try to set the configuration for dev or prod on the client with the new values I’m getting 500 status codes.

GET https://api.colemars.com/dev/notes 500

The previous values still work correctly.

Passing API test:

gateway-cli-test
–username=‘admin@example.com’
–password=‘Passw0rd!’
–user-pool-id=‘us-east-1_MRRQ40XM7’
–app-client-id=‘69tve4h4s4tjnhd93052v8h3ta’
–cognito-region=‘us-east-1’
–identity-pool-id=‘us-east-1:7982caeb-8a8d-4411-8358-e12f5be8a03a’
–invoke-url=‘https://api.colemars.com/dev
–api-gateway-region=‘us-east-1’
–path-template=‘/notes’
–method=‘POST’
–body=‘{“content”:“hello world”,“attachment”:“hello.jpg”}’

Failing client access:

const dev = {
  s3: {
    REGION: "us-east-1",
    BUCKET: "notes-app-2-api-dev-attachmentsbucket-gebtjvlj0ile"
  },
  apiGateway: {
    REGION: "us-east-1",
    URL: "https://api.colemars.com/dev"
  },
  cognito: {
    REGION: "us-east-1",
    USER_POOL_ID: "us-east-1_MRRQ40XM7",
    APP_CLIENT_ID: "69tve4h4s4tjnhd93052v8h3ta",
    IDENTITY_POOL_ID: "us-east-1:7982caeb-8a8d-4411-8358-e12f5be8a03a"
  }
};

Any idea?