auths
objectreturn
or this.key = 'value'
, pass input data to your code viaparams
, and maintain state across executions with$checkpoint.async
(event, steps) => {
}
const axios = require('axios');
const data = 'username=jeremy%40lesptispetons.com&password=*9P0%25vhOWKqxWJi&grant_type=password&scope=read%20write&client_secret=31415926535897&client_id=themisto'
$event.response = (await axios({
method: 'post',
url: 'https://app.opticreche.fr/oauth/token',
data,
headers: {
'Accept': 'application/json, text/plain, */*',
'Connection': 'keep-alive',
'Origin': 'https://app.opticreche.fr',
'Referer': 'https://app.opticreche.fr/',
'Content-Type': 'application/x-www-form-urlencoded',
'Authorization': 'Basic dGhlbWlzdG86MzE0MTU5MjY1MzU4OTc=',
'User-Agent': 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_14_5) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/75.0.3770.100 Safari/537.36',
'Host': 'app.opticreche.fr',
'Accept-Encoding': 'gzip, deflate, br',
'Accept-Language': 'fr-FR,fr;q=0.9,en-US;q=0.8,en;q=0.7'
},
})).data
auths
objectreturn
or this.key = 'value'
, pass input data to your code viaparams
, and maintain state across executions with$checkpoint.async
(event, steps) => {
}
const axios = require('axios');
var options = {
url: 'https://app.opticreche.fr/api/auth/changeStructure/144',
headers: {
'Authorization': 'Bearer ' + $event.response.access_token,
'Accept': 'application/json'
}
}
const response = await axios(options)
auths
objectreturn
or this.key = 'value'
, pass input data to your code viaparams
, and maintain state across executions with$checkpoint.async
(event, steps) => {
}
const axios = require('axios');
var options = {
url: 'https://app.opticreche.fr/api/auth/demande_admission',
headers: {
'Authorization': 'Bearer ' + $event.response.access_token,
'Accept': 'application/json'
}
}
const response = await axios(options)
$event.body = response.data