All Downloads are FREE. Search and download functionalities are using the official Maven repository.

eedm.vendor-contacts.v1.0.0.vendor-contacts.json Maven / Gradle / Ivy

{
  "title" : "Vendor Contacts",
  "description" : "The contacts associated with a vendor.",
  "version" : "1.0.0",
  "type" : "object",
  "properties" : {
    "metadata" : {
      "$ref" : "resource:/eedm/metadata.json"
    },
    "id" : {
      "title" : "ID",
      "description" : "The global identifier of the vendor contact.",
      "type" : "string",
      "format" : "guid",
      "pattern" : "^[a-f0-9]{8}(?:-[a-f0-9]{4}){3}-[a-f0-9]{12}$"
    },
    "vendor" : {
      "title" : "Vendor",
      "description" : "The vendor associated with the contact.",
      "type" : "object",
      "properties" : {
        "id" : {
          "title" : "ID",
          "description" : "The global identifier for the Vendor.",
          "type" : "string",
          "format" : "guid",
          "pattern" : "^[a-f0-9]{8}(?:-[a-f0-9]{4}){3}-[a-f0-9]{12}$"
        }
      },
      "links" : [ {
        "rel" : "self",
        "href" : "/vendors/{id}",
        "targetSchema" : {
          "$ref" : "vendors.json#"
        }
      } ],
      "additionalProperties" : false,
      "required" : [ "id" ]
    },
    "contact" : {
      "title" : "Contact",
      "description" : "The details for the vendor contact.",
      "type" : "object",
      "properties" : {
        "relationshipType" : {
          "title" : "Relationship Type",
          "description" : "The type of relationship between the vendor and the contact.",
          "oneOf" : [ {
            "type" : "object",
            "properties" : {
              "id" : {
                "title" : "ID",
                "description" : "The global identifier for the Relationship Type.",
                "type" : "string",
                "format" : "guid",
                "pattern" : "^[a-f0-9]{8}(?:-[a-f0-9]{4}){3}-[a-f0-9]{12}$"
              }
            },
            "links" : [ {
              "rel" : "self",
              "href" : "/relationship-types/{id}",
              "targetSchema" : {
                "$ref" : "relationship-types.json#"
              }
            } ],
            "additionalProperties" : false,
            "required" : [ "id" ]
          }, {
            "type" : "object",
            "maxProperties" : 0
          } ]
        },
        "person" : {
          "title" : "Person",
          "description" : "The person who is the vendor contact.",
          "type" : "object",
          "properties" : {
            "detail" : {
              "title" : "Detail",
              "description" : "The detail of the person who is the contact.",
              "oneOf" : [ {
                "type" : "object",
                "properties" : {
                  "id" : {
                    "title" : "ID",
                    "description" : "The global identifier for the Detail.",
                    "type" : "string",
                    "format" : "guid",
                    "pattern" : "^[a-f0-9]{8}(?:-[a-f0-9]{4}){3}-[a-f0-9]{12}$"
                  }
                },
                "links" : [ {
                  "rel" : "self",
                  "href" : "/persons/{id}",
                  "targetSchema" : {
                    "$ref" : "persons.json#"
                  }
                } ],
                "additionalProperties" : false,
                "required" : [ "id" ]
              }, {
                "type" : "object",
                "maxProperties" : 0
              } ]
            },
            "name" : {
              "title" : "Name",
              "description" : "The name of the person who is the contact.",
              "type" : "string",
              "minLength" : 1
            }
          },
          "additionalProperties" : false,
          "required" : [ "name" ]
        },
        "phones" : {
          "title" : "Phones",
          "description" : "The phone type, number and extension of the contact person.",
          "type" : "array",
          "items" : {
            "type" : "object",
            "properties" : {
              "type" : {
                "title" : "Type",
                "description" : "The type of phone.",
                "oneOf" : [ {
                  "type" : "object",
                  "properties" : {
                    "id" : {
                      "title" : "ID",
                      "description" : "The global identifier for the Type.",
                      "type" : "string",
                      "format" : "guid",
                      "pattern" : "^[a-f0-9]{8}(?:-[a-f0-9]{4}){3}-[a-f0-9]{12}$"
                    }
                  },
                  "links" : [ {
                    "rel" : "self",
                    "href" : "/phone-types/{id}",
                    "targetSchema" : {
                      "$ref" : "phone-types.json#"
                    }
                  } ],
                  "additionalProperties" : false,
                  "required" : [ "id" ]
                }, {
                  "type" : "object",
                  "maxProperties" : 0
                } ]
              },
              "number" : {
                "title" : "Number",
                "description" : "The number assigned to the phone.",
                "type" : "string"
              },
              "extension" : {
                "title" : "Extension",
                "description" : "The extension used to connect to the phone when multiple phones share the same primary number.",
                "type" : "string"
              }
            },
            "additionalProperties" : false,
            "required" : [ "number" ]
          }
        },
        "startOn" : {
          "title" : "Start On",
          "description" : "The earliest date when the contact is active.",
          "oneOf" : [ {
            "type" : "string",
            "format" : "date",
            "pattern" : "^(-?(?:[1-9][0-9]*)?[0-9]{4})-(1[0-2]|0[1-9])-(3[0-1]|0[1-9]|[1-2][0-9])$"
          }, {
            "type" : "string",
            "maxLength" : 0
          } ]
        },
        "endOn" : {
          "title" : "End On",
          "description" : "The last date when the contact was active.",
          "oneOf" : [ {
            "type" : "string",
            "format" : "date",
            "pattern" : "^(-?(?:[1-9][0-9]*)?[0-9]{4})-(1[0-2]|0[1-9])-(3[0-1]|0[1-9]|[1-2][0-9])$"
          }, {
            "type" : "string",
            "maxLength" : 0
          } ]
        }
      },
      "additionalProperties" : false,
      "required" : [ "person" ]
    }
  },
  "required" : [ "id", "vendor", "contact" ],
  "additionalProperties" : false,
  "links" : [ {
    "rel" : "filter",
    "encType" : "application/x-www-form-urlencoded",
    "method" : "GET",
    "href" : "/vendor-contacts?criteria={\"vendor\": {\"id\": $id}}",
    "title" : "Vendor",
    "description" : "The vendor associated with the contact.",
    "schema" : {
      "type" : "object",
      "properties" : {
        "vendor" : {
          "type" : "object",
          "properties" : {
            "id" : {
              "type" : "string",
              "format" : "guid",
              "pattern" : "^[a-f0-9]{8}(?:-[a-f0-9]{4}){3}-[a-f0-9]{12}$"
            }
          }
        }
      }
    },
    "targetSchema" : {
      "$ref" : "vendor-contacts.json#"
    }
  } ]
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy