• Example

    import { Showpad } from '@showpad/experience-app-sdk'

    const asset = {
    "id": "a3e72bbfae0b87381106b1beb685ea88",
    "slug": "648b2eb8-6fa1-40f2-b787-39cb1d51db69",
    "applink": "showpad://file/648b2eb8-6fa1-40f2-b787-39cb1d51db69",
    "name": "sample.pdf",
    "displayName": "sample",
    "type": "document",
    "description": "",
    "permissions": {
    "share": true,
    "download": true,
    "annotate": true
    },
    "tagIds": [
    "5debee5405cfd4e2797b553037ceb78c"
    ],
    "createdAt": "1970-01-19T21:15:07.909Z",
    "updatedAt": "1970-01-19T23:24:34.801Z",
    "expiresAt": null
    }

    const fileUrl = await Showpad.getAssetFileUrl(asset.id, asset.slug)

    Parameters

    • assetId: string
    • assetSlug: string

    Returns Promise<string>

    A URL to download the full file. This URL can be used within the Showpad apps without authentication. If called outside of the Showpad context, authentication will need to be added manually (eg. by calling getShowpadApi).

Generated using TypeDoc