Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions lib/oa/Course.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ export declare type Course = {
*/
accessibilitySupport?: oa.ConceptOrSubClass[];
/**
* Specifies the physical activity or activities that will take place during a Course.
* Specifies the physical activity or activities associated with this resource.
*
* ```json
* "activity": [
Expand All @@ -83,7 +83,7 @@ export declare type Course = {
*/
activity?: oa.ConceptOrSubClass[];
/**
* Indicates that an event is recommended as being suitable for or is targetted at a specific age range.
* Indicates that this resource is recommended as being suitable for, or is targeted at, a specific age range.
*
* ```json
* "ageRange": {
Expand Down
104 changes: 88 additions & 16 deletions lib/oa/Organization.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -40,10 +40,47 @@ export declare type Organization = {
* The primary purpose of the URI format in this context is to provide natural namespacing for the identifier. Hence, the URI itself may not resolve to a valid endpoint, but must use a domain name controlled by the resource owner (the organisation responsible for the OpenActive open data feed).
*/
'@id'?: string;
/**
* The physical activity or activities provided by this organization.
*
* ```json
* "activity": [
* {
* "@type": "Concept",
* "@id": "https://openactive.io/activity-list#6bb8b844-df3e-4cae-bf5f-3e129c6b1a9d",
* "prefLabel": "Sailing",
* "inScheme": "https://openactive.io/activity-list"
* }
* ]
* ```
*/
activity?: oa.ConceptOrSubClass[];
/**
* Address of the Seller, used on tax receipts.
*/
address?: oa.PostalAddressOrSubClass;
/**
* The age range this organization caters for overall.
*
* ```json
* "ageRange": {
* "@type": "QuantitativeValue",
* "minValue": 5,
* "maxValue": 16
* }
* ```
*/
ageRange?: oa.QuantitativeValueOrSubClass;
/**
* Aliases, common acronyms or alternative names for the organization.
*
* ```json
* "alternateName": [
* "EYC"
* ]
* ```
*/
alternateName?: string[] | string;
/**
* General enquiries e-mail address for the organization.
*
Expand All @@ -52,6 +89,14 @@ export declare type Organization = {
* ```
*/
email?: string;
/**
* Indicates that the organization provides activities that are restricted to male or female participants, or that there are no restrictions.
*
* ```json
* "genderRestriction": "https://openactive.io/FemaleOnly"
* ```
*/
genderRestriction?: oa.GenderRestrictionType;
/**
* Reference to the CustomerAccount associated with this Customer, for use within the Open Booking API flow.
* Note that this property is in EARLY RELEASE AND IS SUBJECT TO CHANGE, as the [Customer Accounts proposal](https://github.com/openactive/customer-accounts) evolves.
Expand All @@ -73,6 +118,31 @@ export declare type Organization = {
* ```
*/
legalName?: string;
/**
* Reference to the license under which the Organization's data is published. Required when an Organization is published on its own outside an RPDE feed; in an RPDE feed, the license is given by each feed page, so it should not be included.
*
* ```json
* "license": "https://creativecommons.org/licenses/by/4.0/"
* ```
*/
license?: string;
/**
* The main address of the organization, or the key locations of the activities it provides.
*
* ```json
* "location": {
* "@type": "Place",
* "@id": "https://example.com/locations/1234ABCD",
* "name": "Example Sailing Club",
* "address": {
* "@type": "PostalAddress",
* "postalCode": "SE10 0BW",
* "addressCountry": "GB"
* }
* }
* ```
*/
location?: string | oa.PlaceOrSubClass[] | oa.PostalAddressOrSubClass | oa.PlaceOrSubClass;
/**
* A logo for the Organization.
*
Expand All @@ -84,6 +154,24 @@ export declare type Organization = {
* ```
*/
logo?: oa.ImageObjectOrSubClass;
/**
* The `@id`s of organizations affiliated to this organization. For example, a national governing body can list its affiliated clubs.
*
* ```json
* "member": [
* "https://example.org/id/organisation/1"
* ]
* ```
*/
member?: string | string[];
/**
* The `@id` of an organization that this organization is affiliated to. For example, a club can link to its national governing body.
*
* ```json
* "memberOf": "https://example.org/id/organisation/national-governing-body"
* ```
*/
memberOf?: oa.OrganizationOrSubClass | string;
/**
* Lists the URL(s) of the official social media profile pages associated with the organization.
*
Expand Down Expand Up @@ -351,22 +439,10 @@ export declare type Organization = {
* An organization identifier that uniquely identifies a legal entity as defined in ISO 17442.
*/
leiCode?: string;
/**
* The location of, for example, where an event is happening, where an organization is located, or where an action takes place.
*/
location?: schema.PlaceOrSubClass | schema.PostalAddressOrSubClass | string | schema.VirtualLocationOrSubClass;
/**
* A pointer to products or services offered by the organization or person.
*/
makesOffer?: schema.OfferOrSubClass | string;
/**
* A member of an Organization or a ProgramMembership. Organizations can be members of organizations; ProgramMembership is typically for individuals.
*/
member?: schema.OrganizationOrSubClass | schema.PersonOrSubClass | string;
/**
* An Organization (or ProgramMembership) to which this Person or Organization belongs.
*/
memberOf?: schema.MemberProgramTierOrSubClass | schema.OrganizationOrSubClass | schema.ProgramMembershipOrSubClass | string;
/**
* A member of this organization.
*/
Expand Down Expand Up @@ -447,10 +523,6 @@ export declare type Organization = {
* use of rdf:type in RDF. Text values can be used sparingly, for cases where useful information can be added without their being an appropriate schema to reference. In the case of text values, the class label should follow the schema.org <a href="https://schema.org/docs/styleguide.html">style guide</a>.
*/
additionalType?: string;
/**
* An alias for the item.
*/
alternateName?: string;
/**
* A sub property of description. A short description of the item used to disambiguate from other, similar items. Information from other properties (in particular, name) may be necessary for the description to be useful for disambiguation.
*/
Expand Down
12 changes: 8 additions & 4 deletions lib/oa/Organization.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,12 +18,20 @@ exports.OrganizationJoiSchema = Joi.object({
name: Joi.string(),
description: Joi.string(),
'@id': Joi.string().uri(),
activity: Joi.array().items(Joi.lazy(() => oa.ConceptOrSubClassJoiSchema)),
address: Joi.lazy(() => oa.PostalAddressOrSubClassJoiSchema),
ageRange: Joi.lazy(() => oa.QuantitativeValueOrSubClassJoiSchema),
alternateName: Joi.alternatives().try(Joi.array().items(Joi.string()), Joi.string()),
email: Joi.string(),
genderRestriction: Joi.lazy(() => oa.GenderRestrictionTypeJoiSchema),
hasAccount: Joi.alternatives().try(Joi.lazy(() => oa.CustomerAccountOrSubClassJoiSchema), Joi.string().uri()),
isOpenBookingAllowed: Joi.boolean(),
legalName: Joi.string(),
license: Joi.string().uri(),
location: Joi.alternatives().try(Joi.string(), Joi.array().items(Joi.lazy(() => oa.PlaceOrSubClassJoiSchema)), Joi.lazy(() => oa.PostalAddressOrSubClassJoiSchema), Joi.lazy(() => oa.PlaceOrSubClassJoiSchema)),
logo: Joi.lazy(() => oa.ImageObjectOrSubClassJoiSchema),
member: Joi.alternatives().try(Joi.string().uri(), Joi.array().items(Joi.string().uri())),
memberOf: Joi.alternatives().try(Joi.lazy(() => oa.OrganizationOrSubClassJoiSchema), Joi.string().uri()),
sameAs: Joi.array().items(Joi.string().uri()),
taxMode: Joi.lazy(() => oa.TaxModeJoiSchema),
telephone: Joi.string(),
Expand Down Expand Up @@ -84,10 +92,7 @@ exports.OrganizationJoiSchema = Joi.object({
legalAddress: Joi.alternatives().try(Joi.lazy(() => schema.PostalAddressOrSubClassJoiSchema), Joi.string().uri()),
legalRepresentative: Joi.alternatives().try(Joi.lazy(() => schema.PersonOrSubClassJoiSchema), Joi.string().uri()),
leiCode: Joi.string(),
location: Joi.alternatives().try(Joi.lazy(() => schema.PlaceOrSubClassJoiSchema), Joi.lazy(() => schema.PostalAddressOrSubClassJoiSchema), Joi.string(), Joi.lazy(() => schema.VirtualLocationOrSubClassJoiSchema), Joi.string().uri()),
makesOffer: Joi.alternatives().try(Joi.lazy(() => schema.OfferOrSubClassJoiSchema), Joi.string().uri()),
member: Joi.alternatives().try(Joi.lazy(() => schema.OrganizationOrSubClassJoiSchema), Joi.lazy(() => schema.PersonOrSubClassJoiSchema), Joi.string().uri()),
memberOf: Joi.alternatives().try(Joi.lazy(() => schema.MemberProgramTierOrSubClassJoiSchema), Joi.lazy(() => schema.OrganizationOrSubClassJoiSchema), Joi.lazy(() => schema.ProgramMembershipOrSubClassJoiSchema), Joi.string().uri()),
members: Joi.alternatives().try(Joi.lazy(() => schema.OrganizationOrSubClassJoiSchema), Joi.lazy(() => schema.PersonOrSubClassJoiSchema), Joi.string().uri()),
naics: Joi.string(),
nonprofitStatus: Joi.lazy(() => schema.NonprofitTypeJoiSchema),
Expand All @@ -107,7 +112,6 @@ exports.OrganizationJoiSchema = Joi.object({
taxID: Joi.string(),
unnamedSourcesPolicy: Joi.alternatives().try(Joi.lazy(() => schema.CreativeWorkOrSubClassJoiSchema), Joi.string().uri()),
additionalType: Joi.alternatives().try(Joi.string(), Joi.string().uri()),
alternateName: Joi.string(),
disambiguatingDescription: Joi.string(),
image: Joi.alternatives().try(Joi.lazy(() => schema.ImageObjectOrSubClassJoiSchema), Joi.string().uri()),
mainEntityOfPage: Joi.alternatives().try(Joi.lazy(() => schema.CreativeWorkOrSubClassJoiSchema), Joi.string().uri()),
Expand Down
4 changes: 2 additions & 2 deletions src/oa/Course.ts
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ export type Course = {
*/
accessibilitySupport?: oa.ConceptOrSubClass[];
/**
* Specifies the physical activity or activities that will take place during a Course.
* Specifies the physical activity or activities associated with this resource.
*
* ```json
* "activity": [
Expand All @@ -85,7 +85,7 @@ export type Course = {
*/
activity?: oa.ConceptOrSubClass[];
/**
* Indicates that an event is recommended as being suitable for or is targetted at a specific age range.
* Indicates that this resource is recommended as being suitable for, or is targeted at, a specific age range.
*
* ```json
* "ageRange": {
Expand Down
Loading
Loading