website logo
⌘K
GETTING STARTED
Getting started with Pathfix
Introduction
OAuth Connect Page
Custom Redirect Domain
Monitoring Activity
Workspace
Extensions
Security
Notifications
Event Callback
Scopes
Provider reference
Access tokens
SDK's
BUBBLE.IO INTEGRATION
Bubble.io Documentation
ADALO INTEGRATION
Adalo Documentation
Adalo User Authorization
Adalo API Call
DEVELOPER CENTER
Developer center
Pathfix Consent Screen (preview)
Module dependencies
Step-by-Step
General
JavaScript
PROVIDER SETUP DOCS
Integration Setup Docs
Identity Auth
Integrating with Airtable
Integrating with Box
Integrating with Hubspot
Integrating with GitHub
Integrating with Google Tasks
Integrating with Instagram Graph API
Integrating with LinkedIn
Integrating with Pipedrive
Integrating with Quickbooks
Integrating with Stripe
Integrating with Stripe-Server
Integrating with Slack
Integrating with TikTok
Integrating with Typeform
Integrating with WooCommerce
Integrating with Xero
Integrating with Zoom
Docs powered by archbee 
6min

$pinc

The $pinc library gives you access to some common functions used across Pathfix. Below are the list of common scenarios where you might use the library.



Get the Pathfix API Call URL or Revoke URL

Syntax

$pinc.getPathfixUrl(providerName, publicKey, userId)

$pinc.getPathfixRevokeUrl(providerName, publicKey, userId)

Remarks

Arguments

Description

providerName

Internal provider name. See Provider reference

publicKey

optional: Defaults to the public key specified in the data-public-key attribute of the script tag

userId

optional: Defaults to the data-user-id attribute of the script tag

Example

JS
|





Read Contents of a file before uploading to Online Storage

Syntax

$pinc.fileRead(FileReader, callback)

Returns

{"type": "HTTP_MIME_TYPE","content": "file_content", uploadObject:{}}

Remarks

Method Call

  • FileReader - required, Javascript FileReader Object
  • callback- callback function reference

Return

  • content - The raw file content.
  • uploadObject - Pass as a parameter to the payload when uploading the file using Pathfix passthrough Endpoints

Example

JS
|

Extended code from developer.mozilla.org

Updated 31 Aug 2022
Did this page help you?
Yes
No
UP NEXT
$pinc.oauth
Docs powered by archbee 
TABLE OF CONTENTS
Get the Pathfix API Call URL or Revoke URL
Read Contents of a file before uploading to Online Storage