mardi 21 avril 2015

aws sdk validation error must be type object

I'm trying to create a record set with the aws sdk and I'm getting this validation error:

Validation errors: [ChangeBatch][Changes][0][Change][ResourceRecordSet][ResourceRecords][Value][ResourceRecord] must be of type object

My code looks like this:

$result = $r53->changeResourceRecordSets(array(
                'HostedZoneId' => 'XXXXXXXXXXXXXXX',
                'ChangeBatch' => array(
                    'Changes' => array(
                        array(
                            'Action' => 'CREATE',
                            'ResourceRecordSet' => array(
                                'Name' => 'psion',
                                'Type' => 'CNAME',
                                'ResourceRecords' => array(
                                    'Value' => 'example.com'
                                ),
                            ),
                            'Change' => array(
                                'ResourceRecordSet' => array(
                                    'ResourceRecords' => array(
                                        'Value' => array(
                                            'ResourceRecord' => $aws->get('Route53'),
                                        ),
                                    ),
                                ),
                            ),
                        ),
                    ),
                ),
            ));

Any idea what the validation error means?




Aucun commentaire:

Enregistrer un commentaire