Skip to content

Repository files navigation

Pitcher API Tutorial: Building Your First Apps

This repository contains example code samples for developers building their first applications with the Pitcher API.

Getting Started

These examples demonstrate common usage patterns for the Pitcher API, from basic "Hello World" applications to more complex entity interactions and Salesforce integrations.

API Documentation

Full API documentation is available at: Pitcher API Documentation

Examples

Hello World Examples

Basic examples showing how to initialize a Pitcher app in different contexts:

Entity Examples

Examples demonstrating how to work with Pitcher entities:

  • Standalone: Working with entities in standalone mode

Salesforce Integration

Examples showing how to integrate with Salesforce:

  • Standalone: Salesforce integration in standalone mode

Multimedia Selector Apps

Examples for multimedia and content selection:

Canvas Embedded Apps

Examples for building apps embedded in Canvas:

  • Canvas Header Overview: Dashboard with goals, cycle plan, and communication updates. Demonstrates JS API usage, Canvas communication via js api events, and dynamic theming.
  • Vite App Example: Canvas sales dashboard built with Vite + React, dev-synced via watch mode

UI Framework Demos

Examples showcasing the Pitcher UI Framework (@pitcher/css):

  • Pitcher UI Demo: Contact manager built with @pitcher/css components — cards, modals, forms, tabs, badges, instance theming

Integrations

Examples integrating an external API through a hosted server component:

  • Financial API Populator: Real-time financial data (Finnhub) via a secure integration server, supporting both DSR (shared links) and Impact (rep) contexts

Web File Apps

Examples for web file applications:

Project Structure

Each example includes:

  • app.json: Configuration file for the application
  • index.html: Main entry point for the application
  • thumbnail.webp: Preview image
  • README.md: Example-specific documentation

Development Guide

Important: Developers should change the app identifier (name) field in the app.json file before publishing their applications.

Publishing Apps

Using Pitcher CLI

You can easily publish your Pitcher apps using the @pitcher/cli-scripts package. This tool simplifies the process of building, validating, and publishing your applications.

  1. Install the CLI tool:

    npm install -g @pitcher/cli-scripts

    This installs the p command line tool.

  2. Navigate to your app directory (containing app.json)

  3. Publish your app:

    p publish-app --api-key [YOURAPIKEY] --increment-version --org [YOURORG]

    Where YOURORG is your organization's specific subdomain. E.g. YOURORG.my.pitcher.com and YOURAPIKEY is your generated API key from YOURORG.my.pitcher.com/admin

For detailed information about all available commands and options, visit: Pitcher CLI Documentation

Additional Resources

About

No description, website, or topics provided.

Resources

Stars

2 stars

Watchers

2 watching

Forks

Releases

Packages

Contributors

Languages