Skip to content

Instantly share code, notes, and snippets.

@arpan-jain
Created May 9, 2019 13:36
Show Gist options
  • Save arpan-jain/f4dbcc1bac9414b0c8a87cac57a60f68 to your computer and use it in GitHub Desktop.
Save arpan-jain/f4dbcc1bac9414b0c8a87cac57a60f68 to your computer and use it in GitHub Desktop.

Revisions

  1. arpan_jain created this gist May 9, 2019.
    305 changes: 305 additions & 0 deletions standings.schema.md
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,305 @@
    # Schema

    ```
    ```

    # Properties

    | Property | Type | Required | Nullable | Defined by |
    | ----------------------------- | ---------- | ------------ | -------- | ------------- |
    | [authRequired](#authrequired) | `boolean` | **Required** | No | (this schema) |
    | [ctaText](#ctatext) | `enum` | **Required** | No | (this schema) |
    | [ctaText2](#ctatext2) | `enum` | **Required** | No | (this schema) |
    | [ctaUri](#ctauri) | `string` | **Required** | No | (this schema) |
    | [ctaUri2](#ctauri2) | `string` | **Required** | No | (this schema) |
    | [data](#data) | `object[]` | **Required** | No | (this schema) |
    | [title](#title) | `enum` | **Required** | No | (this schema) |
    | [type](#type) | `enum` | **Required** | No | (this schema) |

    ## authRequired

    `authRequired`

    - is **required**
    - type: `boolean`
    - defined in this schema

    ### authRequired Type

    `boolean`

    ## ctaText

    `ctaText`

    - is **required**
    - type: `enum`
    - defined in this schema

    The value of this property **must** be equal to one of the [known values below](#ctatext-known-values).

    ### ctaText Known Values

    | Value | Description |
    | ---------------- | ----------- |
    | `View Standings` | |

    ## ctaText2

    `ctaText2`

    - is **required**
    - type: `enum`
    - defined in this schema

    The value of this property **must** be equal to one of the [known values below](#ctatext2-known-values).

    ### ctaText2 Known Values

    | Value | Description |
    | ---------------- | ----------- |
    | `View Standings` | |

    ## ctaUri

    `ctaUri`

    - is **required**
    - type: `string`
    - defined in this schema

    ### ctaUri Type

    `string`

    - format: `uri` – Uniformous Resource Identifier (according to [RFC3986](http://tools.ietf.org/html/rfc3986))
    - minimum length: 1 characters

    ## ctaUri2

    `ctaUri2`

    - is **required**
    - type: `string`
    - defined in this schema

    ### ctaUri2 Type

    `string`

    - format: `uri` – Uniformous Resource Identifier (according to [RFC3986](http://tools.ietf.org/html/rfc3986))
    - minimum length: 1 characters

    ## data

    `data`

    - is **required**
    - type: `object[]`
    - at least `3` items in the array
    - defined in this schema

    ### data Type

    Array type: `object[]`

    All items must be of the type: `object` with following properties:

    | Property | Type | Required |
    | ---------------- | ------- | ------------ |
    | `matchesDrawn` | integer | **Required** |
    | `matchesLost` | integer | **Required** |
    | `matchesPlayed` | integer | **Required** |
    | `matchesTied` | integer | **Required** |
    | `matchesWon` | integer | **Required** |
    | `nrr` | number | **Required** |
    | `points` | integer | **Required** |
    | `position` | integer | **Required** |
    | `teamImage` | string | **Required** |
    | `teamName` | string | **Required** |
    | `teamShortName` | string | **Required** |
    | `tournamentName` | string | **Required** |

    #### matchesDrawn

    `matchesDrawn`

    - is **required**
    - type: `integer`

    ##### matchesDrawn Type

    `integer`

    - minimum value: `0`

    #### matchesLost

    `matchesLost`

    - is **required**
    - type: `integer`

    ##### matchesLost Type

    `integer`

    - minimum value: `0`

    #### matchesPlayed

    `matchesPlayed`

    - is **required**
    - type: `integer`

    ##### matchesPlayed Type

    `integer`

    - minimum value: `0`

    #### matchesTied

    `matchesTied`

    - is **required**
    - type: `integer`

    ##### matchesTied Type

    `integer`

    - minimum value: `0`

    #### matchesWon

    `matchesWon`

    - is **required**
    - type: `integer`

    ##### matchesWon Type

    `integer`

    - minimum value: `0`

    #### nrr

    `nrr`

    - is **required**
    - type: `number`

    ##### nrr Type

    `number`

    #### points

    `points`

    - is **required**
    - type: `integer`

    ##### points Type

    `integer`

    #### position

    `position`

    - is **required**
    - type: `integer`

    ##### position Type

    `integer`

    #### teamImage

    `teamImage`

    - is **required**
    - type: `string`

    ##### teamImage Type

    `string`

    - format: `uri` – Uniformous Resource Identifier (according to [RFC3986](http://tools.ietf.org/html/rfc3986))
    - minimum length: 1 characters

    #### teamName

    `teamName`

    - is **required**
    - type: `string`

    ##### teamName Type

    `string`

    - minimum length: 1 characters

    #### teamShortName

    `teamShortName`

    - is **required**
    - type: `string`

    ##### teamShortName Type

    `string`

    - minimum length: 1 characters

    #### tournamentName

    `tournamentName`

    - is **required**
    - type: `string`

    ##### tournamentName Type

    `string`

    - minimum length: 1 characters

    ## title

    `title`

    - is **required**
    - type: `enum`
    - defined in this schema

    The value of this property **must** be equal to one of the [known values below](#title-known-values).

    ### title Known Values

    | Value | Description |
    | ---------------------- | ----------- |
    | `TOURNAMENT STANDINGS` | |

    ## type

    `type`

    - is **required**
    - type: `enum`
    - defined in this schema

    The value of this property **must** be equal to one of the [known values below](#type-known-values).

    ### type Known Values

    | Value | Description |
    | ---------------------- | ----------- |
    | `TOURNAMENT_STANDINGS` | |