Skip to content

Commit

Permalink
Merge pull request #138 from wuyingfengsui/master
Browse files Browse the repository at this point in the history
支持 dns API
  • Loading branch information
chylvina committed Nov 16, 2017
2 parents e0eb73d + 25205e6 commit 0f02840
Show file tree
Hide file tree
Showing 2 changed files with 189 additions and 0 deletions.
176 changes: 176 additions & 0 deletions apis/dns-2015-01-09.json
@@ -0,0 +1,176 @@
{
"format": "pop",
"apiVersion": "2015-01-09",
"checksumFormat": "md5",
"endpointPrefix": "alidns",
"serviceAbbreviation": "DNS",
"serviceFullName": "Aliyun DNS",
"signatureVersion": "pop",
"timestampFormat": "top",
"xmlnamespace": "",
"operations": {
"describeDomains": {
"name": "DescribeDomains",
"http": {
"method": "POST",
"uri":"/"
},
"input": {
"type": "structure",
"members": {
"Action": {
"required": true,
"default": "DescribeDomains"
},
"PageNumber": {
"type": "integer"
},
"PageSize": {
"type": "integer"
},
"KeyWord": {
"type": "string"
},
"GroupId": {
"type": "string"
}
}
}
},
"describeDomainInfo": {
"name": "DescribeDomainInfo",
"http": {
"method": "POST",
"uri":"/"
},
"input": {
"type": "structure",
"members": {
"Action": {
"required": true,
"default": "DescribeDomainInfo"
},
"DomainName": {
"type": "string"
}
}
}
},
"describeDomainRecords": {
"name": "DescribeDomainRecords",
"http": {
"method": "POST",
"uri":"/"
},
"input": {
"type": "structure",
"members": {
"Action": {
"required": true,
"default": "DescribeDomainRecords"
},
"DomainName": {
"required": true,
"type": "string"
},
"PageNumber": {
"type": "integer"
},
"PageSize": {
"type": "integer"
},
"RRKeyWord": {
"type": "string"
},
"TypeKeyWord": {
"type": "string"
},
"ValueKeyWord": {
"type": "string"
}
}
}
},
"addDomainRecord": {
"name": "AddDomainRecord",
"http": {
"method": "POST",
"uri":"/"
},
"input": {
"type": "structure",
"members": {
"Action": {
"required": true,
"default": "AddDomainRecord"
},
"DomainName": {
"required": true,
"type": "string"
},
"RR": {
"required": true,
"type": "string"
},
"Type": {
"required": true,
"type": "string"
},
"Value": {
"required": true,
"type": "string"
},
"TTL": {
"type": "integer"
},
"Priority": {
"type": "integer"
},
"Line": {
"type": "string"
}
}
}
},
"describeDomainRecordInfo": {
"name": "DescribeDomainRecordInfo",
"http": {
"method": "POST",
"uri":"/"
},
"input": {
"type": "structure",
"members": {
"Action": {
"required": true,
"default": "DescribeDomainRecordInfo"
},
"RecordId": {
"required": true,
"type": "string"
}
}
}
},
"deleteDomainRecord": {
"name": "DeleteDomainRecord",
"http": {
"method": "POST",
"uri":"/"
},
"input": {
"type": "structure",
"members": {
"Action": {
"required": true,
"default": "DeleteDomainRecord"
},
"RecordId": {
"required": true,
"type": "string"
}
}
}
}
}
}
13 changes: 13 additions & 0 deletions samples/dns/test.js
@@ -0,0 +1,13 @@
var ALY = require('../../index.js');

var cdn = new ALY.DNS({
accessKeyId: "在阿里云OSS申请的 accessKeyId",
secretAccessKey: "在阿里云OSS申请的 secretAccessKey",
endpoint: 'http://alidns.aliyuncs.com',
apiVersion: '2015-01-09'
}
);

cdn.describeDomains({}, function(err, res) {
console.log(err, res);
});

0 comments on commit 0f02840

Please sign in to comment.