コード例 #1
0
        public async Task <JObject> GetRecordsWithMainDomainAsync(string mainDomainName)
        {
            var param = new ApiRequestParameters();

            param.AddParameter("Action", "DescribeDomainRecords");
            param.AddParameter("DomainName", mainDomainName);

            param.GenerateSignature();
            var responseStr = await RequestAsync(param);

            return(JObject.Parse(responseStr));
        }
コード例 #2
0
        public async Task <JObject> UpdateRecordAsync(string recordId, string publicIp, SubDomainRecord subDomainRecord)
        {
            var param = new ApiRequestParameters();

            param.AddParameter("Action", "UpdateDomainRecord");
            param.AddParameter("RecordId", recordId);
            param.AddParameter("RR", subDomainRecord.SubDomain);
            param.AddParameter("Type", subDomainRecord.Type);
            param.AddParameter("Value", publicIp);
            param.AddParameter("TTL", subDomainRecord.Interval);

            param.GenerateSignature();
            var responseStr = await RequestAsync(param);

            return(JObject.Parse(responseStr));
        }