Files
crowd-funder-for-time-pwa/src/interfaces/claims.ts
Matthew Raymer e5518cd47c fix: update Vue template syntax and improve Vite config
- Fix Vue template syntax in App.vue by using proper event handler format
- Update Vite config to properly handle ESM imports and crypto modules
- Add manual chunks for better code splitting
- Improve environment variable handling in vite-env.d.ts
- Fix TypeScript linting errors in App.vue
2025-04-18 09:59:33 +00:00

69 lines
2.0 KiB
TypeScript

import { GenericVerifiableCredential } from './common'
export interface AgreeVerifiableCredential {
'@context': string
'@type': string
object: Record<string, unknown>
}
// Note that previous VCs may have additional fields.
// https://endorser.ch/doc/html/transactions.html#id4
export interface GiveVerifiableCredential extends GenericVerifiableCredential {
'@context'?: string
'@type': 'GiveAction'
agent?: { identifier: string }
description?: string
fulfills?: { '@type': string; identifier?: string; lastClaimId?: string }[]
identifier?: string
image?: string
object?: { amountOfThisGood: number; unitCode: string }
provider?: GenericVerifiableCredential
recipient?: { identifier: string }
}
// Note that previous VCs may have additional fields.
// https://endorser.ch/doc/html/transactions.html#id8
export interface OfferVerifiableCredential extends GenericVerifiableCredential {
'@context'?: string
'@type': 'Offer'
description?: string
includesObject?: { amountOfThisGood: number; unitCode: string }
itemOffered?: {
description?: string
isPartOf?: {
identifier?: string
lastClaimId?: string
'@type'?: string
name?: string
}
}
offeredBy?: { identifier: string }
recipient?: { identifier: string }
validThrough?: string
}
// Note that previous VCs may have additional fields.
// https://endorser.ch/doc/html/transactions.html#id7
export interface PlanVerifiableCredential extends GenericVerifiableCredential {
'@context': 'https://schema.org'
'@type': 'PlanAction'
name: string
agent?: { identifier: string }
description?: string
identifier?: string
lastClaimId?: string
location?: {
geo: { '@type': 'GeoCoordinates'; latitude: number; longitude: number }
}
}
// AKA Registration & RegisterAction
export interface RegisterVerifiableCredential {
'@context': string
'@type': 'RegisterAction'
agent: { identifier: string }
identifier?: string
object: string
participant?: { identifier: string }
}