Hi <#C01HWUTP4HH|general> we are trying to send l...
# general
Hi #general we are trying to send logs to signoz through winston logs in localhost , i used the below code to send logs as mentioned in the logs
Copy code
const { diag, DiagConsoleLogger, DiagLogLevel } = require('@opentelemetry/api')
diag.setLogger(new DiagConsoleLogger(), DiagLogLevel.DEBUG);
const { registerInstrumentations } = require('@opentelemetry/instrumentation');
const { ConsoleSpanExporter, InMemorySpanExporter, SimpleSpanProcessor } = require('@opentelemetry/sdk-trace-base');
const { NodeTracerProvider } = require("@opentelemetry/sdk-trace-node");
const { WinstonInstrumentation } = require('@opentelemetry/instrumentation-winston');

const memoryExporter = new InMemorySpanExporter();
const provider = new NodeTracerProvider();
const tracer = provider.getTracer('default');
provider.addSpanProcessor(new SimpleSpanProcessor(new ConsoleSpanExporter()));
  instrumentations: [
    new WinstonInstrumentation({
      enabled: true,
      logHook: (_span, record) => {
        record['resource.service.name'] = 'testLogs';

const winston = require('winston');

const logger = winston.createLogger({
  transports: [
    new winston.transports.Console(),
    new winston.transports.Http({
      host: 'localhost',
      port: 3301,
      path: '/api/v1/logs',
      method: 'POST',
      headers: {
        'Content-Type': 'application/json',

function main() {
  tracer.startActiveSpan('main', (span) => {
    <http://logger.info|logger.info>("Started the span, printing context");
    <http://logger.info|logger.info>("In main main spanning");
  <http://logger.info|logger.info>("Ended span in main");

but not able to see the logs , is there anything i'm missing. if anyone can help me will be great. looking forward for the support from team. running signoz with ./install.sh on localhost port 3301 and node application running on localhost port 5555
``` host: 'localhost',
port: 3301,
path: '/api/v1/logs',```
This is not the correct host:port/path address. The correct one is
. Even if that is fixed, it won’t probably work because the data has to be serialised using the OTLP protocol. I think one way you can do this is to write to file and use the filereceiver to collector logs.