Adds offline payment methods (Pay Later, Bank Transfer, Cash on Delivery) to Orchard Core checkout. Covers settings, net terms, invoicing, transaction recording, and custom offline methods.
Ships in crestapps-orchardcore. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
None: SKILL.md is the whole skill.
Pay Later adds offline payment methods to the checkout. They record a promise to pay instead of moving money, through the same durable ledger and reconciliation as a gateway, and leave a balance in the Transactions ledger that the customer pays later (online from My Transactions or a pay link) or the store records by hand.
Related skills: orchardcore-checkout (providers, payment step), orchardcore-transactions (the balance, reminders, Record payment), orchardcore-payments (provider contracts), orchardcore-subscriptions (recurring plans on Pay Later), orchardcore-carts and orchardcore-orders (orders paid offline show Payment due).
| Feature ID | Category | Depends on |
|---|---|---|
CrestApps.OrchardCore.PayLater (PayLaterConstants.Features.Area) | Commerce | CrestApps.OrchardCore.Checkout, CrestApps.OrchardCore.Transactions |
Install CrestApps.OrchardCore.PayLater in the web project. Enabling the feature offers nothing until a method is turned on in its settings.
{
"steps": [
{
"name": "Feature",
"enable": [ "CrestApps.OrchardCore.PayLater" ],
"disable": []
},
{
"name": "Settings",
"PayLaterSettings": { "Enabled": true, "NetTermDays": 30, "PaymentTermId": null },
"BankTransferSettings": { "Enabled": true, "Instructions": "Contoso Bank, account 000123456, transit 00011.", "NetTermDays": 7 },
"CashOnDeliverySettings": { "Enabled": false, "Instructions": "Pay the courier in cash or by card." }
}
]
}
| Provider | Key | Offered when | Settings (defaults) |
|---|---|---|---|
PayLaterCheckoutPaymentProvider | pay-later | PayLaterSettings.Enabled | Enabled (false), NetTermDays (30; 0 means no due date), PaymentTermId (a Payment Terms term, shown when that feature is on) |
BankTransferCheckoutPaymentProvider | bank-transfer | Enabled and Instructions set | Enabled, Instructions (bank details), NetTermDays (7) |
CashOnDeliveryCheckoutPaymentProvider | cash-on-delivery | Enabled and the checkout has a CheckoutShippingInfo address | Enabled, Instructions |
All three derive from OfflineCheckoutPaymentProvider, which implements ICheckoutPaymentProvider, ICheckoutPaymentProviderAvailability and ICheckoutPaymentProviderDescription, with capabilities one-time only and DefersPayment = true. Verification reports a non-authoritative amount (ReportsAuthoritativeAmount = false), so the checkout records the commitment on its transaction id without an amount cross-check, in GatewayMode.Testing outside Production. Pay Later also implements ICheckoutRecurringPaymentProvider.
Settings live on Settings > Commerce > Offline Payments (group paylater), guarded by ManageTransactionSettings.
PayLaterTransactionCheckoutHandler records, for every succeeded attempt of an OfflineCheckoutPaymentProvider, one outstanding Transaction per obligation: titled after the order (ICheckoutReferenceDescriber), Source equal to the provider key, the guest's name and email from CheckoutContactInfo, due when GetDueUtcAsync(now, payer, cancellationToken) says. Recording is idempotent per obligation. Sources pay-later, bank-transfer and cash-on-delivery are registered with AddTransactionSource.
OfflinePaymentConfirmationDisplayDriver shows the instructions and the reference on the confirmation, which says your order is placed instead of paid.OrderOfflinePaymentDisplayDriver shows what is owed on the order: how to pay for the buyer, a Record payment link to the transaction for the store.PayLaterDueDateResolver picks the most specific term, for the first balance and every renewal cycle:
PartyBillingProfile.PaymentTermId, such as an account on Net 60). A guest has none.PayLaterSettings.PaymentTermId, Settings > Commerce > Offline Payments, Payment term field), shown when the Payment Terms feature of Transactions is on (Invoicing turns it on).NetTermDays (30): days after checkout or after the cycle starts; 0 records no due date.A payment term gives a date (Net 15, end of month, a day of next month), due at the end of that day in the site's time zone. Disabled or deleted terms are skipped. A trial or delayed start counts from the first real cycle. OfflineCheckoutPaymentProvider.GetDueUtcAsync(DateTime now, PartyRef payer, CancellationToken) (virtual, defaults to GetDueUtcAsync(now)) is what the checkout handler asks; Pay Later overrides it, while Bank transfer and Cash on delivery keep their own number of days.
With Invoicing on, every Pay Later balance gets an invoice that takes the debt over: an order's balance gets the order's invoice (from its lines), what another checkout left owing (a subscription's first cycle, a membership) gets a one-line invoice, and each renewal cycle gets an invoice for its period. The invoice is due when the balance is, its number is the one reminders give, and paying it settles the balance. An invoice never offers Pay Later as a way to pay it (DefersPayment).
A deferred provider cannot pay off a balance that already exists (it would mark it paid with nothing received). A checkout with SettlesExistingBalance (paying a transaction from My Transactions or a pay link) never offers it, the engine refuses to begin it there, and settlement ignores deferred attempts.
A Pay Later subscription records the cycle on the transaction (TransactionRecurrence: period, cycle number, cycle limit). PayLaterRenewalBackgroundTask (*/30 * * * *) invoices the next period once the current one ends, copying amount and tax forward, exactly once per cycle under a lock; canceled agreements and those that billed every cycle stop. A trial or delayed start records the first debt for the first real cycle.
Reference CrestApps.OrchardCore.PayLater (the base class is in the module) and register the provider both as ICheckoutPaymentProvider and as OfflineCheckoutPaymentProvider, so the Pay Later handler records its balance:
using CrestApps.OrchardCore.Checkout;
using CrestApps.OrchardCore.PayLater.Services;
using Microsoft.Extensions.Hosting;
using Microsoft.Extensions.Localization;
namespace Contoso.PurchaseOrders;
public sealed class PurchaseOrderCheckoutPaymentProvider : OfflineCheckoutPaymentProvider
{
public const string ProcessorKey = "purchase-order";
internal readonly IStringLocalizer S;
public PurchaseOrderCheckoutPaymentProvider(
IHostEnvironment hostEnvironment,
IStringLocalizer<PurchaseOrderCheckoutPaymentProvider> stringLocalizer)
: base(hostEnvironment)
{
S = stringLocalizer;
}
public override string Key => ProcessorKey;
public override string DisplayName => S["Purchase order"];
public override string Description => S["Place the order now; we invoice your company."];
public override Task<DateTime?> GetDueUtcAsync(DateTime now)
=> Task.FromResult<DateTime?>(now.AddDays(45));
public override Task<bool> IsAvailableAsync(ICheckoutFlowSession session, CancellationToken cancellationToken = default)
=> Task.FromResult(!string.IsNullOrEmpty(session?.OwnerId));
}
using Contoso.PurchaseOrders;
using CrestApps.OrchardCore.Checkout;
using CrestApps.OrchardCore.Checkout.Services;
using CrestApps.OrchardCore.PayLater.Services;
using CrestApps.OrchardCore.Transactions.Core;
using Microsoft.Extensions.DependencyInjection;
using OrchardCore.DisplayManagement.Handlers;
using OrchardCore.Localization;
using OrchardCore.Modules;
[RequireFeatures("CrestApps.OrchardCore.PayLater")]
public sealed class Startup : StartupBase
{
public override void ConfigureServices(IServiceCollection services)
{
services.AddScoped<PurchaseOrderCheckoutPaymentProvider>();
services.AddScoped<ICheckoutPaymentProvider>(sp => sp.GetRequiredService<PurchaseOrderCheckoutPaymentProvider>());
services.AddScoped<OfflineCheckoutPaymentProvider>(sp => sp.GetRequiredService<PurchaseOrderCheckoutPaymentProvider>());
// A panel for the payment step: an IDisplayDriver<CheckoutFlowPaymentMethod> grouped by the key.
services.AddDisplayDriver<CheckoutFlowPaymentMethod, PurchaseOrderPaymentMethodDisplayDriver>();
services.AddTransactionSource(PurchaseOrderCheckoutPaymentProvider.ProcessorKey, source =>
{
source.DisplayName = LocalizationSource.Create<Startup>("Purchase order");
});
}
}
The panel driver returns View("PurchaseOrderCheckoutPaymentMethod", method).Location("Content").OnGroup(PurchaseOrderCheckoutPaymentProvider.ProcessorKey).
PayLaterSettings.Enabled is set.DefersPayment provider and is no longer accepted to settle an existing balance.| Symptom | Cause |
|---|---|
| Method not on the payment step | Not enabled in settings, bank transfer without instructions, cash on delivery without a shipping address, or the checkout settles an existing balance |
| No transaction after checkout | The checkout did not complete, or the method is not registered as OfflineCheckoutPaymentProvider |
| Recurring Pay Later invoiced once | Background tasks not running |
| Due date ignores Net term (days) | The payer's billing profile or PayLaterSettings.PaymentTermId names a payment term, which wins |
| Payment term field missing in Settings > Commerce > Offline Payments | Enable the Payment Terms feature (Invoicing turns it on) |
| Receipts or reminders never reach a guest | No email service, or the Contact step was off so no email was collected |
What SKILL.md sets; muted values are Claude Code's defaults
/crestapps-orchardcore:orchardcore-pay-laterfrom crestapps-orchardcore
npx claudepluginhub crestapps/crestapps.agentskills --plugin crestapps-orchardcore137 skills in this plugin
/orchardcore-accountsSkill for the CrestApps Orchard Core Accounts module (CrestApps.OrchardCore.Accounts) with its Account Members, Account Team, Account E-mail Domains and Account Locations features. Covers the Account type and AccountPart, the account picker and search, IAccountChildTypeRule, account page sections (AccountPageTabs, AddPageSection, Notes), members and IAccountMemberService, account invitations, the account owner and team picked from staff, e-mail domains, locations with a billing location, the account's billing profile and party members, the Accounts recipe and deployment steps, and the admin menu. Use this skill when requests mention accounts, the businesses or households records belong to, an account page tab, members, invitations, owners, domains or locations. Strong matches include AccountPart, AccountPageTabs, IAccountMemberService, IAccountInvitationService, AccountInvitation, AccountTeamPart, AccountEmailDomainsPart, IAccountEmailDomains, AccountLocationsPart and ManageAccountMembers./orchardcore-accounts-b2bSkill for the CrestApps Orchard Core Accounts B2B module (CrestApps.OrchardCore.Accounts.B2B), business selling on an Account content item. Covers B2BAccountPart and B2BAccount, buyers as account members and ship-to addresses as account locations, terms (deposit, net days, credit limit) through the account-terms tender billed to the account, the account's billing profile, purchase order numbers, quotes, price lists through IBuyerPriceProvider, order limits, approvals and budgets, OCI punchout, the account/business page and API, the PriceLists recipe and deployment steps, the B2BAccounts report source, and the move from the removed Companies module. Use this skill when requests mention B2B, wholesale or business buyers, net terms, purchase orders, price lists, order approvals or punchout. Strong matches include B2BAccountPart, B2BAccount, AccountTerms, AccountTermsTenderProvider, B2BAccountBillingProfileSource, IB2BAccountStore, PriceList, B2BPriceProvider, B2BApprovalService and ManageB2BAccounts.Other plugins' skills for the same job