SNS implementtion of IOS

981 views Asked by At

Im trying to create an application using AWS SDK with the following code.

$AmazonSNS->createPlatformApplication(array(
    'Name'=>"GameplandevApns",
    'Platform'=>'APNS',
    'Attributes'=>array(                       
        'PlatformPrincipal'=>'safdafafsafasasafdafa',
        'PlatformCredential'=>'asfdafdsadfsafasfsasa'   
    )                       
));

I am getting the error:

Invalid parameter: PlatformPrincipal not valid.

What is wrong with my code?

1

There are 1 answers

0
George Lin On

For APNS, the PlatformPrincipal is used for the SSL certificate from Apple while the PlatformCredential is the private key. Here is the Getting Started Guide for APNS and the Create Platform Application API docs.