Logs are not Pushing to Elastic APM Server - FastAPI

I have installed elastic-apm agent with my FastAPI application. I have configured the Elastic APM server. The logs are generated locally but these logs I can't able to see it on Elastic APM server.

Here is the configuration, I have set.

apm = make_apm_client({
'SERVER_URL': "Logstash URL",
'SERVICE_NAME': '<index_name>--metrics',
'SECRET_TOKEN': '',
'DEBUG': True,
'ENVIRONMENT': 'dev',
})
app.add_middleware(ElasticAPM, client=apm)

The logs are generated in local (used ecs-logging package),
{"@timestamp":"2022-12-23T13:18:18.634Z","log.level":"info","message":"retriving Internal User IP -> Test APM Server","ecs":{"version":"1.6.0"},"log":{"logger":"elasticapm","origin":{"file":{"line":54,"name":"app.py"},"function":"graph"},"original":"retriving Internal User IP -> Test APM Server"},"process":{"name":"SpawnProcess-1","pid":203,"thread":{"id":1642,"name":"MainThread"}},"service":{"name":"test-index--metrics"},"trace":{"id":"8128f5a24214660ca5c69e3c3f36"},"transaction":{"id":"c3ea48535e7b"}}

Kindly help me what I have missed in the configuration. I can't able to see the logs in APM server.