目录

fields

Parameter NameTypeMandatory or OptionalDescription
countryCodeStringOptionalCountry code.
currencyCodeStringOptionalCurrency code.
statusstatusOptionalStatus information that you have defined, including the status of a pass and the time when the pass expires.
relatedPassIdsrelatedPassIdsOptionalID of a linked pass, if any.
locationListlocationListOptionalGeographical location. This parameter can be used if the pass supports geofence notifications.
barCodebarCodeOptionalBarcode or QR code, which is displayed when a pass is used. Leave this parameter empty if the barcode or QR code need not be displayed.
commonFieldsList<valueObject>OptionalList of common displayable fields, namely, attributes of a type of pass.
appendFieldsList<valueObject>OptionalList of additional displayable fields, which are defined by the issuer to distinguish the same type of passes in different scenarios.
messageListList<valueObject>OptionalNotification for a pass, which is irrelevant with the common displayable fields of the pass. It is used to notify users, for example, of using the pass in a given period of time.
timeListList<valueObject>OptionalList of time information.
imageListList<valueObject>OptionalList of images that are displayed in a succession on the pass details page, for example, hotel pictures and services that are displayed successively on a hotel loyalty card.
textListList<valueObject>OptionalTexts that you have defined, which will be displayed in a list on the pass details page.
localizedlocalizedOptionalLocal language, which is defined here and referenced by other fields through the corresponding key when the fields need to be displayed in the local language.
ticketInfoListList<valueObject>OptionalDescription of a ticket stub that you have defined.
urlListList<valueObject>OptionalLinks to be show on a pass.

Example

  1. {
  2.  "fields": {
  3.    "countryCode": "zh-cn",
  4.    "currencyCode": "CNY",
  5.    "status": {
  6.      "state": "active",
  7.      "effectTime": "2019-11-13T00:00:00.111Z",
  8.      "expireTime": "2019-11-20T00:00:00.111Z"
  9.    },
  10.    "locationList": [
  11.      {
  12.        "longitude": "114.0679603815",
  13.        "latitude": "22.6592051284"
  14.      }
  15.    ],
  16.    "barCode": {
  17.      "text": "1118466050",
  18.      "type": "codabar",
  19.      "value": "1118466050",
  20.      "encoding": "UTF-8"
  21.    },
  22.    "commonFields": [
  23.      {
  24.        "key": "Number",
  25.        "value": "356688115",
  26.        "label": "NumberLabel",
  27.        "localizedValue": "Number"
  28.      }
  29.    ],
  30.    "appendFields": [
  31.      {
  32.        "key": "homepageUri",
  33.        "value": "https://www.huawei.com/",
  34.        "label": "homepadepartureDateTimegeUriLabel"
  35.      }
  36.    ],
  37.    "messageList": [
  38.      {
  39.        "key": "message[0]",
  40.        "value": "Lorem ipsum dolor sit amet, consecetetur adipiscing elit. Phasellus ac mi ex. Integer sollicitudin eu metus quis vehicula",
  41.        "label": "message"
  42.      },
  43.      {
  44.        "key": "message[1]",
  45.        "value": "consecetetur adipiscing elit. Phasellus ac mi ex.",
  46.        "label": "message[1]Label"
  47.      }
  48.    ],
  49.    "textList": [
  50.      {
  51.        "key": "text[0]",
  52.        "value": "Integer sollicitudin eu metus quis vehicula",
  53.        "label": "Text Module"
  54.      },
  55.      {
  56.        "key": "text[1]",
  57.        "value": "Lorem ipsum dolor sit amet, consecetetur adipiscing elit",
  58.        "label": "text[1]Label"
  59.      }
  60.    ],
  61.    "imageList": [
  62.      {
  63.        "redirectUrl": "https://www.huawei.com",
  64.        "value": "https://obs.cn-north-2.myhwclouds.com/nsp-hiwallet-pass-p02-drcn/serviceCard/img/FC2215CF30922A9719CCC03B41B4047C.jpg",
  65.        "label": "mainImage[0]label",
  66.        "key": "mainImage[0]"
  67.      },
  68.      {
  69.        "redirectUrl": "https://www.huawei.com",
  70.        "value": "https://obs.cn-north-2.myhwclouds.com/nsp-hiwallet-pass-p02-drcn/serviceCard/img/9D170D0030C719B2FA295B341EFB1A11.png",
  71.        "label": "mainImage[1]label",
  72.        "key": "mainImage[1]"
  73.      }
  74.    ],
  75.    "urlList": [
  76.      {
  77.        "key": "detail",
  78.        "value": "https://huawei.vmall.com/"
  79.      },
  80.      {
  81.        "key": "Main Image",
  82.        "value": "https://www.huawei.com/XXX1.png"
  83.      }
  84.    ],
  85.    "localized": [
  86.      {
  87.        "key": "cardName",
  88.        "language": "zh-cn",
  89.        "value": "Vmall gift card"
  90.      }
  91.    ]
  92.  }
  93. }