Overview
The CommonGrants.Fields namespace contains a standard set of fields that are used to build more complex models.
Fields
Section titled “Fields”Learn more about the standard fields defined by the CommonGrants protocol:
AddressA physical address
Custom FieldA model for defining custom fields on a record
EventA description of an event with an associated date
FileA file attachment
System MetadataSystem-managed metadata for records
MoneyA monetary amount with a currency code
NameA person's name
PhoneA phone number
PCS termPhilanthropy Classification System (PCS) term
You can use the fields listed above (along with basic data types) above to define custom models in your TypeSpec project.
import "@common-grants/core"
// Exposes the `Fields` and `Types` namespaces so that they can be accessed// without a `CommonGrants` prefixusing CommonGrants;
model Widget { id: Types.uuid; // CommonGrants-defined type description: string; // Standard TypeSpec type price: Fields.Money; // CommonGrants-defined field}