import { axios } from "@pipedream/platform"
export default defineComponent({
props: {
oto: {
type: "app",
app: "oto",
}
},
async run({steps, $}) {
return await axios($, {
url: `${this.oto.$auth.api_url}/rest/v2/accountInfo`,
headers: {
Authorization: `Bearer ${this.oto.$auth.oauth_access_token}`,
},
})
},
})
Emit new event when the status of an order changes. See the documentation
Provides detailed information about a specific order. See the documentation
OTO uses OAuth authentication. When you connect your OTO account, Pipedream will open a popup window where you can sign into OTO and grant Pipedream permission to connect to your account. Pipedream securely stores and automatically refreshes the OAuth tokens so you can easily authenticate any OTO API.
Pipedream requests the following authorization scopes when you connect your account:
POST
{{custom_fields.api_url}}/rest/v2/refreshToken
accept: application/json
refresh_token={{custom_fields.refresh_token}}
POST
{{custom_fields.api_url}}/rest/v2/refreshToken
accept: application/json
refresh_token={{custom_fields.refresh_token}}