Skip to content

Launch Center Pro

Launch Center Pro is an iOS launcher for running actions and shortcuts. Protocol Launcher allows you to generate deep links for Launch Center Pro actions documented by Contrast.

Usage

There are two ways to use this library:

  • On-Demand import from subpaths enables tree-shaking and keeps bundles small.
  • Full Import from the root package is convenient but includes all app modules.

Pick On-Demand for production builds; Full Import is fine for quick scripts or demos.

Select Installation Method

On-Demand
Recommended. Optimized for production.
Full Import
Convenient. Good for quick scripts.

URL Methods

These helpers follow Contrast's official x-callback-url Support, Dropbox Actions, Scheduling Action Notifications, and release note examples. Undocumented or discontinued Launch Center Pro actions are not wrapped.

Open App

On-Demand
ts
import { open } from 'protocol-launcher/launch-center-pro'

const url = open()

Brightness

On-Demand
ts
import { brightness } from 'protocol-launcher/launch-center-pro'

const url = brightness()

const callbackUrl = brightness({
  xSuccess: 'tweetbot://',
})

Clipboard

On-Demand
ts
import { clipboard } from 'protocol-launcher/launch-center-pro'

const textUrl = clipboard({
  text: 'mytext',
})

const photoUrl = clipboard({
  attach: 'photo:last',
})

Define

On-Demand
ts
import { define } from 'protocol-launcher/launch-center-pro'

const url = define()

Speak

On-Demand
ts
import { speak } from 'protocol-launcher/launch-center-pro'

const url = speak({
  text: 'Hello master!',
})

const callbackUrl = speak({
  text: 'Hello master!',
  xSuccess: '[action:15]',
})

Email

On-Demand
ts
import { email } from 'protocol-launcher/launch-center-pro'

const url = email({
  to: 'sample@contrast.co',
  subject: 'Last Photo',
  body: '',
  cc: '',
  bcc: '',
  attach: 'photo:last',
})

Messaging

On-Demand
ts
import { messaging } from 'protocol-launcher/launch-center-pro'

const photoUrl = messaging({
  to: '555-555-5555',
  attach: 'photo:last',
})

const dropboxPhotoUrl = messaging({
  to: '555-555-5555',
  body: '[prompt:Body]',
  attach: 'photo:dropbox',
  path: 'reactions',
})

const gifUrl = messaging({
  attach: 'photo:gif',
  'gif-search': 'excited',
})

Dropbox

On-Demand
ts
import { dropbox } from 'protocol-launcher/launch-center-pro'

const url = dropbox()

Dropbox Add Photo

On-Demand
ts
import { dropboxAddPhoto } from 'protocol-launcher/launch-center-pro'

const url = dropboxAddPhoto({
  attach: 'photo:frontcamera',
  path: '/selfies/',
})

const callbackUrl = dropboxAddPhoto({
  attach: 'photo:last',
  path: '/snaps/',
  getlink: 'yes',
  xSuccess: 'launch://tweet?text=[clipboard]',
})
On-Demand
ts
import { dropboxCopyDirectLink } from 'protocol-launcher/launch-center-pro'

const url = dropboxCopyDirectLink()

Schedule Action Notification

On-Demand
ts
import { schedule } from 'protocol-launcher/launch-center-pro'

const actionUrl = schedule({
  action: 179,
  in: '1h',
  repeat: 'specificdays',
  days: 'm,tu,w,th,f',
})

const urlNotification = schedule({
  url: '[url:https://apple.com]',
  in: '10min',
})

Share Sheet

On-Demand
ts
import { shareSheet } from 'protocol-launcher/launch-center-pro'

const url = shareSheet({
  attach: 'photo:last',
  text: '[prompt-fleksy:Notes]',
  url: '[clipboard]',
})

QR Action

On-Demand
ts
import { qr } from 'protocol-launcher/launch-center-pro'

const url = qr()

Dropbox New Text File

On-Demand
ts
import { dropboxNew } from 'protocol-launcher/launch-center-pro'

const url = dropboxNew({
  text: '[prompt-return:My Note]',
  path: '/Notes/',
  name: 'MyFile.markdown',
  overwrite: 'NO',
})

Dropbox Append Text

On-Demand
ts
import { dropboxAppend } from 'protocol-launcher/launch-center-pro'

const url = dropboxAppend({
  text: 'Next line',
  name: 'MyFile.markdown',
  linebreak: 'NO',
})

Dropbox Prepend Text

On-Demand
ts
import { dropboxPrepend } from 'protocol-launcher/launch-center-pro'

const url = dropboxPrepend({
  text: 'First line\nBody',
  name: 'note_[firstline].text',
  leavefirstline: 'NO',
})

Dropbox Clipboard

On-Demand
ts
import { dropboxClipboard } from 'protocol-launcher/launch-center-pro'

const browserUrl = dropboxClipboard()

const linkUrl = dropboxClipboard({
  path: '/photos/',
  linkonly: 'yes',
})