import { axios } from "@pipedream/platform"
export default defineComponent({
props: {
otter_waiver: {
type: "app",
app: "otter_waiver",
}
},
async run({steps, $}) {
return await axios($, {
url: `https://api.otterwaiver.com/waivers`,
headers: {
Authorization: `Bearer ${this.otter_waiver.$auth.oauth_access_token}`,
},
})
},
})
Otter Waiver uses OAuth authentication. When you connect your Otter Waiver account, Pipedream will open a popup window where you can sign into Otter Waiver and grant Pipedream permission to connect to your account. Pipedream securely stores and automatically refreshes the OAuth tokens so you can easily authenticate any Otter Waiver API.
Pipedream requests the following authorization scopes when you connect your account:
POST
https://api.otterwaiver.com/auth/connect
accept: application/json
content-type: application/json
client_id={{custom_fields.client_id}}
&
client_secret={{custom_fields.client_secret}}
&
grant_type=client_credentials
POST
https://api.otterwaiver.com/auth/connect
accept: application/json
client_id={{custom_fields.client_id}}
&
client_secret={{custom_fields.client_secret}}
&
grant_type=client_credentials