paystack-payment-pages

Paystack Payment Pages API — create and manage hosted payment pages for collecting payments without writing frontend code. Supports fixed/flexible amounts, custom slugs, subscription pages, product pages, split payments, redirects, custom fields, and phone collection. Use this skill whenever building checkout pages, donation pages, event ticket sales, product catalogs with payments, or any hosted payment link. Also use when you see references to page slug, /page endpoint, paystack.com/pay/ URLs, or need to add products to a payment page.

Safety Notice

This listing is imported from skills.sh public index metadata. Review upstream SKILL.md and repository scripts before running.

Copy this and send it to your AI assistant to learn

Install skill "paystack-payment-pages" with this command: npx skills add rexedge/paystack/rexedge-paystack-paystack-payment-pages

Paystack Payment Pages

The Payment Pages API lets you create hosted payment pages at https://paystack.com/pay/[slug] — no frontend code needed.

Depends on: paystack-setup for the paystackRequest helper.

Endpoints

MethodEndpointDescription
POST/pageCreate a payment page
GET/pageList payment pages
GET/page/:id_or_slugFetch a payment page
PUT/page/:id_or_slugUpdate a payment page
GET/page/check_slug_availability/:slugCheck slug availability
POST/page/:id/productAdd products to page

Create Payment Page

POST /page

ParamTypeRequiredDescription
namestringYesPage name
descriptionstringNoPage description
amountintegerNoFixed amount in subunits (kobo/pesewas)
currencystringNoDefaults to integration currency
slugstringNoCustom URL slug
typestringNopayment (default), subscription, product, or plan
planstringNoPlan ID (when type is subscription)
fixed_amountbooleanNoIf true, amount is required and unchangeable
split_codestringNoSplit code for revenue sharing
redirect_urlstringNoRedirect URL after payment
success_messagestringNoSuccess message on completion
notification_emailstringNoEmail for transaction notifications
collect_phonebooleanNoCollect phone numbers
custom_fieldsarrayNoCustom fields to collect
metadataobjectNoExtra config (subaccount, logo, etc.)
// Simple payment page
const page = await paystackRequest<{
  slug: string;
  id: number;
}>("/page", {
  method: "POST",
  body: JSON.stringify({
    name: "Buttercup Brunch",
    amount: 500000, // ₦5,000
    description: "Gather your friends for the ritual that is brunch",
    slug: "buttercup-brunch",
    redirect_url: "https://mysite.com/thank-you",
    collect_phone: true,
  }),
});
// Page URL: https://paystack.com/pay/buttercup-brunch

// Subscription page
await paystackRequest("/page", {
  method: "POST",
  body: JSON.stringify({
    name: "Monthly Pro Plan",
    type: "subscription",
    plan: 1716,
  }),
});

// Donation page (flexible amount)
await paystackRequest("/page", {
  method: "POST",
  body: JSON.stringify({
    name: "Support Our Cause",
    description: "Any amount helps",
    // No amount = donor chooses
    custom_fields: [
      { display_name: "Full Name", variable_name: "full_name" },
      { display_name: "Message", variable_name: "message" },
    ],
  }),
});

List Payment Pages

const pages = await paystackRequest("/page?perPage=20&page=1");

Fetch Payment Page

const page = await paystackRequest(`/page/${encodeURIComponent("buttercup-brunch")}`);

Update Payment Page

await paystackRequest(`/page/${encodeURIComponent("buttercup-brunch")}`, {
  method: "PUT",
  body: JSON.stringify({
    name: "Updated Brunch",
    description: "New brunch description",
    amount: 750000,
    active: true,
  }),
});

Check Slug Availability

const check = await paystackRequest(
  `/page/check_slug_availability/${encodeURIComponent("my-slug")}`
);
// { status: true, message: "Slug is available" }

Add Products to Page

await paystackRequest(`/page/${pageId}/product`, {
  method: "POST",
  body: JSON.stringify({
    product: [473, 292], // Product IDs
  }),
});

Source Transparency

This detail page is rendered from real SKILL.md content. Trust labels are metadata-based hints, not a safety guarantee.

Related Skills

Related by shared tags or category signals.

General

paystack-charges

No summary provided by upstream source.

Repository SourceNeeds Review
General

paystack-webhooks

No summary provided by upstream source.

Repository SourceNeeds Review
General

paystack-transfers

No summary provided by upstream source.

Repository SourceNeeds Review