JSON schema

The event listing call should return an object of type eventListImport. this schema references the eventImport schema, which in turn references the eventDisciplineImport schema.

eventListImport schema

The result of the eventList call should be an array of eventImport objects.

{
  "$schema": "http://json-schema.org/draft-07/schema#",
  "$id": "http://scoreexpress.io/schema/v1/eventListImport.schema.json",
  "title": "Event Import",
  "description": "default schema for importing events from third party systems, such as federations competition management",
  "type": "array",
  "items": {
    "$ref": "eventImport.schema.json"
  }
}

eventImport schema

For each event, following fields are used:

  • id: ID of the event in the source system.
  • title: title of the event.
  • titleShort: Optional shorter version of the title, optional.
  • dateFrom: first date of the event, format YYYY-MM-DD
  • dateTo: last date of the event, format YYYY-MM-DD
  • venue: place or venue name for the event.
  • disciplines: array of eventDisciplineImport objects included in the event, see below for details.

Following fields can be provided with the import data, but should actually already be set automatically from the default values configured in the ScoreExpress user account:

  • copyright: copyright line to include in documents.
  • logo: base64 content of the logo file.
  • country: 3 character code of the country of the event (e.g. ‘BEL’). See https://en.wikipedia.org/wiki/List_of_IOC_country_codes for the list of country codes.
  • language: 2 character code of the language preference for the event, current options: ‘en’, ‘nl’, ‘fr’.
{
  "$schema": "http://json-schema.org/draft-07/schema#",
  "$id": "http://scoreexpress.io/schema/v1/eventImport.schema.json",
  "title": "Event Import",
  "description": "default schema for importing events from third party systems, such as federations competition management",
  "type": "object",
  "properties": {
    "id": {
      "description": "ID of the event in the source system",
      "type": "string"
    },
    "title": {
      "description": "Title of the event",
      "type": "string"
    },
    "titleShort": {
      "description": "Shortened title of the event, optional",
      "type": "string"
    },
    "dateFrom": {
      "description": "first date of the event",
      "type": "string",
      "pattern": "\\d\\d\\d\\d-\\d\\d-\\d\\d",
      "format": "date"
    },
    "dateTo": {
      "description": "last date of the event",
      "type": "string",
      "pattern": "\\d\\d\\d\\d-\\d\\d-\\d\\d",
      "format": "date"
    },
    "venue": {
      "description": "name of the venue or city of the event",
      "type": "string"
    },
    "country": {
      "description": "IOC code of the country, optional, defaults to the organizer country",
      "type": "string",
      "minLength": 3,
      "maxLength": 3
    },
    "language": {
      "description": "two character code for the language, optional, defaults to organizer language",
      "type": "string",
      "minLength": 2,
      "maxLength": 2
    },
    "copyright": {
      "description": "event copyright line, optional, defaults to organizer copyright",
      "type": "string"
    },
    "logo": {
      "description": "base64 string with the logo image, svg, png or jpeg, optional",
      "type": "string"
    },
    "disciplines": {
      "description": "list of disciplines included in the event",
      "type": "array",
      "minItems": 1,
      "items": {
        "$ref": "eventDisciplineImport.schema.json"
      }
    }
  },
  "required": ["id", "title", "dateFrom", "dateTo", "disciplines"]
}

eventDisciplineImport schema

This object type contains the general information of the event discipline included in an event.
Following fields apply:

  • id: id of the eventDiscipline in the source system.
  • title: title of the eventDiscipline.
  • titleShort: optional shorter version of the title.
  • code: code used to link the eventDiscipline the corresponding ScoreExpress discipline.
  • copyright: optional copyright line, defaults to value set on the event level.
  • logo; optional, base64 logo file contents.
{
  "$schema": "http://json-schema.org/draft-07/schema#",
  "$id": "http://scoreexpress.io/schema/v1/eventDisciplineImport.schema.json",
  "title": "Event Discipline Import",
  "description": "default schema for importing event disciplines from third party systems, such as federations competition management",
  "type": "object",
  "properties": {
    "id": {
      "description": "ID of the event discipline in the source system",
      "type": "string"
    },
    "title": {
      "description": "Title of the event discipline",
      "type": "string"
    },
    "titleShort": {
      "description": "Shortened title of the event, optional",
      "type": "string"
    },
    "code": {
      "description": "ScoreExpress code for the discipline",
      "type": "string"
    },
    "copyright": {
      "description": "event discipline copyright line, optional, defaults to event copyright",
      "type": "string"
    },
    "logo": {
      "description": "base64 string with the logo image, svg, png or jpeg",
      "type": "string"
    }
  },
  "required": ["id", "title", "code"]
}

Example

[{
  "id": "123455767",
  "title": "National Championships Acrobatic & Rhythmic Gymnastics of Neverland",
  "titleShort": "NC Acrobatic & Rhythmic Gymnastics",
  "dateFrom": "2019-11-29",
  "dateTo": "2019-11-30",
  "venue": "Neverland Sports Centre",
  "country": "BEL",
  "language": "en",
  "copyright": "www.scoreexpress.be",
  "logo": "data:image/svg+xml;base64,PD94bWw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of Neverland",
    "titleShort": "NC Acrobatic Gymnastics",
    "code": "gym-acro"
  }, {
    "id": "36998457",
    "title": "National Championships Rhythmic Gymnastics of Neverland",
    "titleShort": "NC Rhythmic Gymnastics",
    "code": "gym-rg"
  }]
}]

Feedback

Was this helpful?

Yes No
You indicated this topic was not helpful to you ...
Could you please leave a comment telling us why? Thank you!
Thanks for your feedback.

Post your comment on this topic.

Post Comment