RFC Generator Mexico

फ़्री
द्वारा jfhe88 | अपडेट किया गया a month ago | Tools
लोकप्रियता

9.3 / 10

लेटेंसी

224ms

सेवा का स्तर

100%

Health Check

N/A

सभी चर्चाओं पर वापस जाएं

adding the api to google apps script

Rapid account: Tlamaki
tlamaki
a year ago
hello, i'm having some troubles while adding the api to google's apps script, if i try with "message" i get a succesflu response, this is the code:

function rfch(ape1,ape2,nombre,fecha) {

rfc = encodeURI(rfc);
var response = UrlFetchApp.fetch(“https://jfhe88-rfc-generator-mexico.p.rapidapi.com/rest1/rfc/get?apellido_materno="+ape2+"&apellido_paterno="+ape1+"&fecha="+fecha+"&nombre="+nombre+"&solo_homoclave=0&rapidapi-key=KEY”);

if (String(response.getResponseCode())[0] === ‘4’){
return “”
}

var w = JSON.parse(response.getContentText());

return [ [w.response[“message”]] ]

}

But if i try to get the RFC field then i can’t get it to work, here is the code i’m using for rfc:
function rfch(ape1,ape2,nombre,fecha) {
rfc = encodeURI(rfc);
var response = UrlFetchApp.fetch(“https://jfhe88-rfc-generator-mexico.p.rapidapi.com/rest1/rfc/get?apellido_materno="+ape2+"&apellido_paterno="+ape1+"&fecha="+fecha+"&nombre="+nombre+"&solo_homoclave=0&rapidapi-key=KEY”);

if (String(response.getResponseCode())[0] === ‘4’){
return “”
}

var w = JSON.parse(response.getContentText());

return [ [w.response[“rfc”]] ]

}

चर्चा में शामिल हों - नीचे टिप्पणी जोड़ें:

नई टिप्पणियाँ पोस्ट करने के लिए लॉग इन / साइनअप करें