sns-q.js
function(arn, token, data, attributes) {
        var params = {
            PlatformApplicationArn: arn,
            Token: token,
            CustomUserData: data,
            Attributes: attributes
        };

        return this.svc.createPlatformEndpoint(params);
    }
function(arn, token, data, attributes) {
        var params = {
            PlatformApplicationArn: arn,
            Token: token,
            CustomUserData: data,
            Attributes: attributes
        };

        return this.svc.createPlatformEndpoint(params);
    }
function ( arn , token , data , attributes ) { var params = { PlatformApplicationArn : arn , Token : token , CustomUserData : data , Attributes : attributes } ; return this . svc . createPlatformEndpoint ( params ) ; }
creates an endpoint for a device, within the specified application

@param {String} name name of the platformApplication object
@param {String} platform the platform this application object targets (APNS, GCM, ADM)
@param {Object} attributes additional attributes provided

for more information regarding the additional attributes, see:
http://docs.aws.amazon.com/sns/latest/api/API_SetEndpointAttributes.html
creates an endpoint for a device within the specified application