Fast analytics with the friendly UX and integrated tooling to let your company explore data on their own.
Go to siteimport { axios } from "@pipedream/platform"
export default defineComponent({
props: {
metabase: {
type: "app",
app: "metabase",
}
},
async run({steps, $}) {
return await axios($, {
url: `${this.metabase.$auth.server_address}/api/user/current`,
headers: {
"X-Metabase-Session": `${this.metabase.$auth.oauth_access_token}`,
},
})
},
})
Metabase uses OAuth authentication. When you connect your Metabase account, Pipedream will open a popup window where you can sign into Metabase and grant Pipedream permission to connect to your account. Pipedream securely stores and automatically refreshes the OAuth tokens so you can easily authenticate any Metabase API.
Pipedream requests the following authorization scopes when you connect your account:
POST
{{custom_fields.server_address}}/api/session
content-type: application/x-www-form-urlencoded
accept: application/json
username={{custom_fields.username}}
&
password={{custom_fields.password}}
POST
{{custom_fields.server_address}}/api/session
content-type: application/x-www-form-urlencoded
accept: application/json
username={{custom_fields.username}}
&
password={{custom_fields.password}}