-
Notifications
You must be signed in to change notification settings - Fork 35
SQS Client
SaltwaterC edited this page Jan 20, 2012
·
3 revisions
aws.load('sqs', [accessKeyId], [secretAccessKey])
sqs.request(action, [query], callback)
The 'action' argument is the action required by the SQS query API itself.
- sqs.setQueue(queue)
- sqs.setPath([path])
- sqs.setCredentials(accessKeyId, secretAccessKey)
- sqs.setRegion(region)
- sqs.setMaxSockets(numberOfSockets)
- sqs.getEndPoint()
- sqs.getApiVersion()
- sqs.setApiVersion(apiVersion)
// init the client
var sqs = require('aws2js').load('sqs', accessKeyId, secretAccessKey);
// call something of the SQS query API
sqs.request('action', {foo: 'bar'}, function (error, response) {
if (error) {
console.error(error);
} else {
console.log(response);
}
});