# Fungies ## Docs - [Authentication](https://docs.fungies.io/api-reference/authentication.md): Learn how to authenticate your API requests using public and secret keys. - [Archive a discount](https://docs.fungies.io/api-reference/discounts/archive-a-discount.md): Archive (soft delete) a discount by its ID. Archived discounts can no longer be used at checkout but remain in the system for reporting purposes. This action is reversible. - [Create a new discount](https://docs.fungies.io/api-reference/discounts/create-a-new-discount.md): Create a new discount with the specified details. Discounts can be either: - Coupon codes: Customers enter a code at checkout to receive the discount - Sale discounts: Automatically applied based on conditions Both fixed amount and percentage-based discounts are supported. - [Get discount details](https://docs.fungies.io/api-reference/discounts/get-discount-details.md): Retrieve detailed information about a specific discount by its ID. Returns the full discount object including usage statistics and associated products/offers. - [List discounts](https://docs.fungies.io/api-reference/discounts/list-discounts.md): Retrieve a paginated list of discounts with powerful filtering options. Discounts can be coupon codes that customers enter at checkout, or automatic sale discounts applied based on conditions. Results are sorted by creation date (newest first) by default. - [Update a discount](https://docs.fungies.io/api-reference/discounts/update-a-discount.md): Update an existing discount's details. You can modify the name, amount, expiration, and other properties. Note: Changing the discount code may affect customers who have saved the old code. - [Create a new Checkout Element](https://docs.fungies.io/api-reference/elements/create-a-new-checkout-element.md): Create a new Checkout Element with specified offers. Checkout Elements are embeddable or hosted checkout experiences that can be integrated into your website or application. They handle the entire checkout flow including payment collection, tax calculation, and order creat… - [List checkout elements](https://docs.fungies.io/api-reference/elements/list-checkout-elements.md): Retrieve a paginated list of checkout elements. Returns all checkout elements created for your workspace, including their associated offers and configuration settings. Results are sorted by creation date (newest first). - [Introduction](https://docs.fungies.io/api-reference/introduction.md): Learn how to integrate with the Fungies API to manage products, process payments, and handle subscriptions. - [Add product keys](https://docs.fungies.io/api-reference/offers/add-product-keys.md): Add product keys (license keys, game keys, etc.) to an offer. Keys are automatically assigned to customers upon successful purchase. Each key can only be used once. - [Archive an offer](https://docs.fungies.io/api-reference/offers/archive-an-offer.md): Archive (soft delete) an offer by its ID. Archived offers can no longer be purchased but existing subscriptions continue. This action is reversible. - [Create a new offer](https://docs.fungies.io/api-reference/offers/create-a-new-offer.md): Create a new offer for a product. Offers define how a product can be purchased: - One-time purchase: Set price and currency, leave recurring fields empty - Subscription: Set price, currency, and recurring interval - Free: Set price to 0 For subscription offers, you can… - [Get offer details](https://docs.fungies.io/api-reference/offers/get-offer-details.md): Retrieve detailed information about a specific offer by its ID. Returns the full offer object including product reference, variant details, pricing, subscription settings, and inventory status for key-based products. - [List offers](https://docs.fungies.io/api-reference/offers/list-offers.md): Retrieve a paginated list of offers with powerful filtering options. Offers represent purchasable configurations of products, including pricing, currency, and subscription settings. A single product can have multiple offers for different pricing tiers or billing intervals. Res… - [Remove specific unsold key](https://docs.fungies.io/api-reference/offers/remove-specific-unsold-key.md): Remove a specific unsold key from an offer by its ID. Only unsold keys can be removed. Sold keys cannot be deleted. - [Remove unsold keys](https://docs.fungies.io/api-reference/offers/remove-unsold-keys.md): Remove all unsold keys from an offer. This action permanently deletes keys that have not been assigned to customers. Sold keys are preserved for record-keeping. - [Update an offer](https://docs.fungies.io/api-reference/offers/update-an-offer.md): Update an existing offer's details. Can modify name, price, and settings. Note that changing pricing on an active offer may affect existing subscription customers depending on your configuration. - [Cancel order](https://docs.fungies.io/api-reference/orders/cancel-order.md): Cancel a specific order by changing its status to CANCELLED. This action does not automatically process refunds. To refund a paid order, use the refund endpoint or process through your payment provider. Requires write access. - [Get order details](https://docs.fungies.io/api-reference/orders/get-order-details.md): Retrieve detailed information about a specific order by its ID or order number. Returns the full order object including associated user, cart items, subscription (if applicable), and payment details. For subscription orders, also returns the current subscription status. - [List orders](https://docs.fungies.io/api-reference/orders/list-orders.md): Retrieve a paginated list of orders with powerful filtering options. Orders represent purchases made by customers, including one-time purchases, subscription initiation, and free product claims. Subscription renewal payments are tracked as separate payment objects, not orders. Resul… - [Update order](https://docs.fungies.io/api-reference/orders/update-order.md): Modify an existing order's details. Can update status, value, fee, tax, and currency. Requires write access. Note: Use with caution as this directly modifies order records. For most cases, use the refund or cancel endpoints instead. - [Get payment details](https://docs.fungies.io/api-reference/payments/get-payment-details.md): Retrieve detailed information about a specific payment by its ID. Returns the full payment object including associated user, order, subscription, charges, and invoice details. - [List payments](https://docs.fungies.io/api-reference/payments/list-payments.md): Retrieve a paginated list of payments with powerful filtering options. Payments represent individual transactions including one-time purchases, subscription payments, and refunds. Results are sorted by creation date (newest first) by default. - [Add a plan to a product](https://docs.fungies.io/api-reference/products/add-a-plan-to-a-product.md): Add a new subscription plan to an existing product. Plans are variants specifically for subscription products, typically representing different billing intervals or tiers. - [Add a variant to a product](https://docs.fungies.io/api-reference/products/add-a-variant-to-a-product.md): Add a new variant (configuration option) to an existing product. Variants allow the same product to have different configurations, such as different durations, tiers, or sizes. Each variant can have its own offers. - [Archive a plan](https://docs.fungies.io/api-reference/products/archive-a-plan.md): Archive (soft delete) a plan by its ID. Existing subscriptions on this plan continue. This action is reversible. - [Archive a product](https://docs.fungies.io/api-reference/products/archive-a-product.md): Archive (soft delete) a product by its ID. Archived products are hidden from the store and cannot be purchased. Associated offers are also archived. Existing subscriptions continue. This action is reversible. - [Archive a variant](https://docs.fungies.io/api-reference/products/archive-a-variant.md): Archive (soft delete) a variant by its ID. Associated offers are also affected. This action is reversible. - [Create a new product](https://docs.fungies.io/api-reference/products/create-a-new-product.md): Create a new product with the specified details. Products can be one of several types: - OneTimePayment: Standard products purchased once - Subscription: Products with recurring billing - Membership: Access-based products - GameKey: Digital key distribution After cr… - [Duplicate a product](https://docs.fungies.io/api-reference/products/duplicate-a-product.md): Create a copy of an existing product with all its variants. The duplicated product will have a new ID and slug. Offers are not duplicated. - [Get product details](https://docs.fungies.io/api-reference/products/get-product-details.md): Retrieve detailed information about a specific product by its ID. Returns the full product object including variants, media, and associated offers. - [List products](https://docs.fungies.io/api-reference/products/list-products.md): Retrieve a paginated list of products with powerful filtering options. Products are the core items available for sale. Each product can have multiple variants (different configurations) and offers (different pricing options). Results are sorted by creation date (newest first) by de… - [Update a plan](https://docs.fungies.io/api-reference/products/update-a-plan.md): Update an existing plan's details. - [Update a product](https://docs.fungies.io/api-reference/products/update-a-product.md): Update an existing product's details. Can modify name, description, media, and other properties. Note: The product slug cannot be changed after creation to prevent broken URLs. - [Update a variant](https://docs.fungies.io/api-reference/products/update-a-variant.md): Update an existing variant's details. - [Cancel Subscription](https://docs.fungies.io/api-reference/subscriptions/cancel-subscription.md): Cancel a Subscription with specified options for timing and refunds. - [Charge Subscription](https://docs.fungies.io/api-reference/subscriptions/charge-subscription.md): Charge an additional amount to an active Subscription. Creates a new Invoice and handles payment processing. - [Create Subscription](https://docs.fungies.io/api-reference/subscriptions/create-subscription.md): Create a new Subscription for a User. User must have a valid customer ID of Payment Provider set. Requires billing details with at least a country code and postal code if country is one of US, CA, UA, IN. Note: User must have a valid customer ID of Payment Provider set and this cust… - [Get Subscription](https://docs.fungies.io/api-reference/subscriptions/get-subscription.md): Retrieve detailed information about a specific Subscription. - [List Subscriptions](https://docs.fungies.io/api-reference/subscriptions/list-subscriptions.md): Search and filter Subscriptions with pagination. Results are sorted by creation date (newest first) by default. - [Pause Subscription Collection](https://docs.fungies.io/api-reference/subscriptions/pause-subscription-collection.md): Pause a Subscription's payment collection temporarily with options for handling payments. During the pause period: - No charges will be made - Access to subscription benefits will be maintained - Can be resumed manually or automatically at a specified time - [Update Subscription](https://docs.fungies.io/api-reference/subscriptions/update-subscription.md): Update Subscription items and handle proration behavior. Can modify prices, quantities, and add/remove items. - [Archive User](https://docs.fungies.io/api-reference/users/archive-user.md): Soft delete (archive) a User account. This action is reversible. - [Create a new User account](https://docs.fungies.io/api-reference/users/create-a-new-user-account.md): Creates a new User account in the system. The email must be unique across all Users. Returns the created User object with all fields except the password. Note: If billingDetails are provided, ensure the countryCode is valid and postalCode is included for required countries. - [Get User object](https://docs.fungies.io/api-reference/users/get-user-object.md): Get detailed information about a specific User. - [Get User's inventory items](https://docs.fungies.io/api-reference/users/get-users-inventory-items.md): Retrieve a complete list of items in the User's inventory with filtering options. This includes: - All purchased products - Subscription items - Limited-time access items Use filters to narrow down results by product type or expiration date. - [List and filter Users](https://docs.fungies.io/api-reference/users/list-and-filter-users.md): Retrieve a paginated list of Users with powerful filtering options. Results are sorted by creation date (newest first) by default. Note: Timestamps can be provided in either seconds or milliseconds since Unix epoch. - [Unarchive User](https://docs.fungies.io/api-reference/users/unarchive-user.md): Restore a User account that has been previously archived. - [Update User details](https://docs.fungies.io/api-reference/users/update-user-details.md): Update an existing User's data and billing details. - [Discount](https://docs.fungies.io/core-resources/discount.md): The Discount object represents a price reduction that can be applied to purchases. - [Event](https://docs.fungies.io/core-resources/event.md): The Event object represents a webhook notification about activity in your Fungies store. - [Offer](https://docs.fungies.io/core-resources/offer.md): The Offer object represents a purchasable pricing option for a product. - [Order](https://docs.fungies.io/core-resources/order.md): The Order object represents a purchase transaction in your Fungies store. - [Overview](https://docs.fungies.io/core-resources/overview.md): Understand how Fungies API objects relate to each other. - [Payment](https://docs.fungies.io/core-resources/payment.md): The Payment object represents a financial transaction in your Fungies store. - [Product](https://docs.fungies.io/core-resources/product.md): The Product object represents a sellable item in your Fungies store. - [Subscription](https://docs.fungies.io/core-resources/subscription.md): The Subscription object represents a recurring billing relationship with a customer. - [User](https://docs.fungies.io/core-resources/user.md): The User object represents a customer in your Fungies store. - [Billing Data Prefill](https://docs.fungies.io/developers/checkout-elements/billing-data.md): Prefill customer billing information in checkout to streamline purchases. - [HTML Data Attributes](https://docs.fungies.io/developers/checkout-elements/html-attributes.md): Add checkout buttons to your website using simple HTML data attributes. - [Checkout Elements Overview](https://docs.fungies.io/developers/checkout-elements/overview.md): Embed checkout experiences directly in your website or redirect customers to hosted checkout pages. - [JavaScript SDK](https://docs.fungies.io/developers/checkout-elements/sdk.md): Integrate Fungies checkout using the JavaScript SDK. - [Custom Domain Setup](https://docs.fungies.io/developers/custom-domain/overview.md): Connect your own domain to your Fungies storefront for a seamless brand experience. - [Custom Fields Overview](https://docs.fungies.io/developers/customer-data/overview.md): Collect additional customer data during checkout to identify users in your system. - [Set Up Custom Fields](https://docs.fungies.io/developers/customer-data/setup.md): Create custom fields in the Fungies Dashboard to collect customer data during checkout. - [Validate Customer Data](https://docs.fungies.io/developers/customer-data/validate.md): Ensure data quality with regex patterns or custom validation endpoints. - [Webhooks Overview](https://docs.fungies.io/developers/webhooks/overview.md): Receive real-time event notifications from Fungies in your application. - [Set Up Webhooks](https://docs.fungies.io/developers/webhooks/setup.md): Create and configure a webhook endpoint to receive Fungies events. - [Test Webhooks](https://docs.fungies.io/developers/webhooks/test.md): Test your webhook integration locally before deploying to production. ## OpenAPI Specs - [api-docs](https://docs.fungies.io/api-reference/api-docs.yaml) - [package](https://docs.fungies.io/package.json) - [openapi](https://docs.fungies.io/api-reference/openapi.json) ## Optional - [Help Center](https://help.fungies.io/) - [Discord](https://discord.gg/yfH5ZyTZH4)