GithubHelp home page GithubHelp logo

Comments (1)

defiantgoat avatar defiantgoat commented on July 20, 2024

Tile Package Tool Deep Linking Spec

The tile package tool uses the x-callback-url specification (http://x-callback-url.com/specifications/).

The parameters listed below are based on using the current Portal object and the parameters it provides.

Research suggests that a maximum character length of 2000 for a url is still advisable.

arcgis-tilepackage://x-callback-url/[action]?[action parameters]&[x-callback parameters]

Note: the parameters are URL encoded

Protocol

x-callback-url protocol is defined in http://x-callback-url.com/

Actions [REQUIRED]

/create

Create a new tile package

Request Parameters

  • refreshToken [optional]
    current refresh token if available
    Portal.refreshToken

  • handoffClientId [required if refreshToken sent]
    application clientId
    Portal.clientId

  • tileService [optional]
    unique id of the tile service if known

  • center [optional]
    lat and long in decimal coordinates for map center
    center=12.434343,33.00909

  • zoomLevel [optional]
    Desired zoom level to display the export map at on startup. This is just for convenience for the user and doesn't restrict changing once in the Tile Package Tool.

  • saveToPath [optional]
    Path to desired location to save TPK to locally. Note: If user decided to upload tpk to AGOL portal then local file will be deleted after upload. Should be encoded

Return Parameters

  • isShared [Boolean]
    true || false : If the tile package was shared with the organization or public

  • isOnline [Boolean]
    true = tile package was uploaded to arcgis online
    false = tile package was saved local

  • itemId [Returned if isOnline=true]
    AGOL id

  • localPath [Returned if isOnline=false]
    path to local file

===

/upload

Upload a local tile package to online

Request Parameters

  • refreshToken [optional]
    current refresh token if available
    Portal.refreshToken

  • handoffClientId [required if refreshToken sent]
    application clientId
    Portal.clientId

  • filePath [optional]
    Encoded filepath to the .tpk file that should be uploaded online.

Return Parameters

  • isShared [Boolean]
    true || false : If the tile package was shared with the organization or public

  • itemId
    AGOL id

x-callback parameters

This is optional but recommended for better user experience

  • x-source: Name of application calling Tile Package Tool (e.g. Survey123)
    This is the same as callbackprompt used in current Esri url schemes

  • x-success : URL to open on completion task.
    This is analogous to callback parameter used in current Esri url schemes

  • x-cancel : URL to open if the requested action is cancelled by the user.

  • x-error : URL to open if the requested action generates an error or failed to complete.

Examples

arcgis-tilepackage://x-callback-url/create?token=4-cvk290NVFk2f9ozqgYQidFz5NPZXe-ZMrqI1nqlxTifWhPR6IhkqSXdvZPC2G8_4R9wyHxTX1u6TmN5L_FgAx_LyAUrMxXJHolIEaeLDZfUmURBMrTEO1Xn9a9TLOUb6FMrwfwpHGhRWFA7xMAZcGLxmTJyi_Pqa84fd_hPxKqQ2meD4ApAfSCCp52GWC4ODn8ihwzNJh-nbAzZY9SHw..&username=bilbo_baggins&canpublish=true&center=13.298383,-89.383838&savelocal=false&tileservice=Dark%20Gray&x-source=Survey123&x-success=arcgis-survey123://

from tilepackagekreator.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.