coding, javascript, nodejs

Parse Server – providing ip of a client

Very handy code that can be used for analytics (reversing to approximate location)

let ip = request.headers[‘x-forwarded-for’] || request.connection.remoteAddress || request.socket.remoteAddress || request.connection.socket.remoteAddress;

This is for cloud defined functions for your custom rest API

Share This: