Contribution

A sponsorship (GitHub) or order (Open Collective), normalized.

On this page

A sponsorship (GitHub) or order (Open Collective), normalized.

import type { Contribution } from "@sponsorkit/sdk";

interface Contribution { … }

Interface, exported from @sponsorkit/sdk, @sponsorkit/sdk/node, @sponsorkit/sdk/server.

Properties#

id#

id: string

Stable id: con_<provider>_<hash>.

provider#

provider: Provider

Type: Provider

target#

target: string

Target string, e.g. github:octocat.

sponsor: SponsorEntity

Type: SponsorEntity

via#

via: "direct" | "organization"

kind#

kind: ContributionKind

Type: ContributionKind

frequency#

frequency: Frequency

Type: Frequency

status#

status: ContributionStatus

Type: ContributionStatus

amount#

amount: Money

Type: Money

tier#

tier: { id: string; name: string } | null

flags#

flags: "via_patreon"[]

private#

private: boolean

startedAt#

startedAt: string | null

endedAt#

endedAt: string | null

lastChargedAt#

lastChargedAt: string | null

nextChargeAt#

nextChargeAt: string | null

totalContributed#

totalContributed: Money | null

Type: Money