## Stripe Apps: Building and Managing Integrated Applications

This documentation section provides a comprehensive guide to developing, deploying, and managing applications within the Stripe ecosystem. It covers the entire lifecycle of building a Stripe App, from initial setup and authentication to UI development, distribution, and ongoing maintenance.

### Core Concepts and Getting Started

*   **Stripe Apps Overview**: Understand the fundamental purpose and capabilities of Stripe Apps, which allow for extending Stripe's functionality and embedding custom user interfaces directly into the Stripe Dashboard.
*   **Getting Started with Stripe Apps**: Learn the basics of app development, including building, previewing, and updating a sample "Hello, world!" app.
*   **How Stripe Apps Work**: Delve into the architecture of Stripe Apps, understanding their frontend (UI extensions) and backend components, and how they interact with the Stripe API.
*   **Common Use Cases**: Explore various application types (backend, frontend, full-stack) and their typical use cases, providing a roadmap for your development.

### Development and Integration

*   **Build an App**: This section guides you through the process of creating a new Stripe App.
*   **Store Secret Credentials and Tokens**: Learn how to securely persist sensitive data like authentication credentials using the Secret Store API.
*   **API Authentication Methods**: Understand the different methods for authenticating requests to the Stripe API, including Platform keys, OAuth 2.0, and Restricted API keys.
    *   **OAuth 2.0**: Detailed guide on implementing OAuth 2.0 for secure user authentication.
    *   **Restricted API Key Authentication**: Learn how to leverage Restricted API Keys (RAKs) for more granular access control.
*   **Add Authorization Flows**: Implement PKCE OAuth workflows to enable secure authorization between your app and third-party services.
*   **Add Server-Side Logic**: Integrate backend code to validate and process user actions and data, enabling secure third-party system integrations and webhook event handling.
*   **Build a UI**: Develop custom user interfaces within the Stripe Dashboard using TypeScript, React, and Stripe's UI Extensions SDK and UI toolkit.
    *   **How UI Extensions Work**: Understand the system for rendering your own UI within Stripe's products.
    *   **Next Generation UI Components**: Explore early access to updated UI components for enhanced functionality.
    *   **UI Components Reference**: A catalog of available UI components for building your app's interface, including:
        *   Layout and structural components: `Box`, `Inline`, `Stack`, `Grid`
        *   Interactive elements: `Button`, `ButtonGroup`, `Checkbox`, `Radio`, `Switch`, `TextField`, `TextArea`, `Select`, `Menu`, `Tabs`
        *   Data display: `Accordion`, `Badge`, `Banner`, `BarChart`, `Chip`, `DataTable`, `DateField`, `LineChart`, `List`, `PropertyList`, `Sparkline`, `Table`
        *   Navigation and flow: `Link`, `Route Descriptors`, `OnboardingView`, `SignInView`, `SettingsView`, `FocusView`, `ContextView`, `FullPageView`, `FullPageTabs`
        *   Status indicators: `Spinner`, `Toast`, `Tooltip`
        *   Specialized components: `Icon`, `Img`, `Divider`, `FormFieldGroup`, `DetailPageModule`, `DetailPagePropertyList`, `DetailPageTable`, `TaskList`, `OverviewPage`
*   **Component Hierarchy Constraints**: Understand the rules governing how UI components can be composed to ensure predictable UI behavior.
*   **Design Your App**: Get started with design tools, guidelines, and philosophy for creating a cohesive app experience.
*   **Style Your App**: Learn how to style UI components using provided design tokens to match the Stripe Dashboard's visual style.
*   **Design Patterns**: Follow recommended design patterns for common app scenarios to ensure consistency and clarity.
    *   **Full Page Apps**: Design complete, multi-view interfaces within the Stripe Dashboard.
    *   **Action Buttons**: Strategically place action buttons for optimal user interaction.
    *   **Onboarding Flow**: Create effortless, customizable, and relevant onboarding experiences.
    *   **Additional Context**: Provide necessary information to users before they sign in.
    *   **Back Link**: Implement clear navigation to previous pages.
    *   **Communicating State**: Inform users about temporary status or required actions.
    *   **Demo Content**: Display concise demonstrations of your app's core functionality.
    *   **Empty State**: Clearly indicate when no data is available to load.
    *   **Filter Controls**: Enable users to filter table rows using Chip components.
    *   **Lists**: Display collections of information effectively.
    *   **Loading**: Use Spinner components to indicate data loading.
    *   **Progress Stepping**: Guide users through multi-step tasks.
    *   **Redirects**: Create clear redirects for user navigation.
    *   **Settings Sign In**: Onboard users via a settings page for backend-only apps.
    *   **Sign In Template**: Implement a secure and user-friendly sign-in process.
    *   **Sign Out**: Provide a clear mechanism for users to sign out.
    *   **Waiting Screens**: Inform users about wait times and next steps during onboarding.

### Testing and Deployment

*   **Enable Sandbox Support**: Allow users to install your app in Stripe's testing environments for evaluation.
*   **Handle Different Modes**: Adapt your app to function correctly in both live mode and sandboxes.
*   **Enable Local Network Access**: Configure your browser to allow local network connections for app previewing.
*   **Test Your App Externally**: Set up and distribute test versions of your app to gather feedback before public release.
*   **Upload and Install Your Stripe App**: Make your app available to team members on your Stripe account.
*   **Distribution Options**: Understand the methods for sharing your Stripe Apps with users, including public and private distribution.
    *   **How to Publish an App to the Stripe App Marketplace**: Guide to getting your app approved for the public marketplace.
    *   **Stripe Apps Quality Requirements**: Learn about the qualitative requirements for apps listed on the App Marketplace.
*   **Manage Your App's Versions and Releases**: Implement app versioning and releases to manage changes over time.

### Migration and Legacy

*   **Migrate an Extension to Stripe Apps**: Understand why and how to migrate legacy extensions to the modern Stripe Apps platform.
    *   **Migrate a plugin to Stripe Apps or Stripe Connect**: Decide on your migration path from legacy plugins.
    *   **Migrate a plugin to an OAuth 2.0 app**: Convert your plugin to use OAuth 2.0 authentication.
    *   **Migrate a plugin to a RAK app**: Convert your plugin to use Restricted API Key authentication.
*   **Legacy Extensions**: Information and reference for the deprecated extensions integration pattern.

### Reference and Tools

*   **App Manifest Reference**: Understand the structure and fields of your app's manifest file (`stripe-app.json`).
*   **Stripe Apps CLI Reference**: Install and use the command-line interface to manage your app's lifecycle.
*   **Permissions Reference**: Learn about available events and their required permissions for your app.
*   **Extension SDK API Reference**: Documentation for the Extension SDK API, providing context props and utility functions for UI extensions.
*   **Viewports Reference**: Understand the available viewports where your UI extensions can be displayed within the Stripe Dashboard.