Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feat/ams form additions #784

Merged
merged 12 commits into from
Oct 3, 2023
71 changes: 58 additions & 13 deletions docs/openapi/components/schemas/common/AgricultureProduct.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,13 +30,6 @@ properties:
$linkedData:
term: plu
'@id': https://schema.org/identifier
rhofvendahl marked this conversation as resolved.
Show resolved Hide resolved
countryOfOrigin:
title: Country of Origin
description: The country in which this product originated.
type: string
$linkedData:
term: countryOfOrigin
'@id': https://vocabulary.uncefact.org/originCountry
product:
title: Product
description: Product details as specified in the Product schema.
Expand Down Expand Up @@ -76,7 +69,51 @@ properties:
type: string
$linkedData:
term: labelImageHash
'@id': https://schema.org/sha256
'@id': https://w3id.org/traceability#labelImageHash
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

too bad we don't have a better term def for this

name:
title: Name
description: Name of the agricultural product.
type: string
$linkedData:
term: name
'@id': https://schema.org/name
productImageUrl:
title: Product Image URL
description: Image of the product.
type: string
$linkedData:
term: productImageUrl
'@id': https://schema.org/url
productImageHash:
title: Product Image Hash
description: >-
Hash value for securely identifying the product image. More information can
be found at the following link: https://cybersecurityglossary.com/hashing
type: string
$linkedData:
term: productImageHash
'@id': https://w3id.org/traceability#productImageHash
variety:
title: Variety
description: "Additional details regarding the product. For example, in this case of potatoes, this might include: russet, white, yellow flesh, etc."
type: string
$linkedData:
term: variety
'@id': https://www.gs1.org/voc/consumerProductVariant
commodityDesignation:
title: Commodity Designation
description: "Additional product subcategories such as: frozen, fresh, sliced, canned, dried, dehydrated, etc."
type: string
$linkedData:
term: commodityDesignation
'@id': https://www.gs1.org/voc/additionalProductDescription
rhofvendahl marked this conversation as resolved.
Show resolved Hide resolved
packType:
title: Pack Type
description: "Details like: volume filled, tray pack, 18/lb consumer units, 10/5 pound bags, etc."
type: string
$linkedData:
term: packType
'@id': https://www.gs1.org/voc/packaging
additionalProperties: true
required:
- type
Expand Down Expand Up @@ -132,8 +169,16 @@ example: |-
"unitCode": "kg",
"value": "4890"
},
"sku": "712120934258",
"imageUrl": "https://img.example.org/102934920857/937/903/",
"imageHash": "8kb47j986hklhde4rfh78okjhgjo08765fgu7tfg4t864fy876rfser45thj87f3"
}
}
"sku": "71266019767"
},
"scientificName": "Persea americana",
"plantParts": "fruit",
"labelImageUrl": "https://img.example.org/033383401508/640/480/",
"labelImageHash": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855",
"name": "Avocados",
"productImageUrl": "https://img.example.org/102934920857/937/903/",
"productImageHash": "8kb47j986hklhde4rfh78okjhgjo08765fgu7tfg4t864fy876rfser45thj87f3",
"variety": "Firm",
"commodityDesignation": "Whole, fresh",
"packType": "4-pack boxes"
}
8 changes: 8 additions & 0 deletions docs/openapi/components/schemas/common/Product.yml
Original file line number Diff line number Diff line change
Expand Up @@ -164,6 +164,14 @@ properties:
$linkedData:
term: imageHash
'@id': https://schema.org/sha256
htsCode:
title: HTS Code
description: The Harmonized Tariff Schedule (HTS) code, if applicable.
type: string
$linkedData:
term: htsCode
'@id': https://service.unece.org/trade/uncefact/vocabulary/uncefact/#applicableTax

additionalProperties: false
required:
- type
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,13 @@ properties:
$linkedData:
term: auditProgramsRequested
'@id': https://www.gs1.org/voc/certificationType
countByInspector:
title: Count by Inspector
description: Whether the count of the packages was counted by the inspector.
type: boolean
$linkedData:
term: countByInspector
'@id': https://schema.org/values
additionalRemarks:
title: Additional Remarks
description: Any additional remarks regarding the application.
Expand Down Expand Up @@ -184,5 +191,6 @@ example: |-
"auditProgramsRequested": [
"Produce GAPs Harmonized Audit: Field Operations & Harvesting",
"Plant Systems Audit"
]
],
"countByInspector": true
}
16 changes: 14 additions & 2 deletions docs/openapi/openapi.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2060,7 +2060,7 @@ paths:
$ref: './components/schemas/common/USMCACertifier.yml'


/schemas/common/USMCAProductSpecifier.yml:
/schemas/common/USMCAClaims.yml:
get:
tags:
- common
Expand All @@ -2069,7 +2069,19 @@ paths:
content:
application/yml:
schema:
$ref: './components/schemas/common/USMCAProductSpecifier.yml'
$ref: './components/schemas/common/USMCAClaims.yml'


/schemas/common/USMCAProduct.yml:
get:
tags:
- common
responses:
'200':
content:
application/yml:
schema:
$ref: './components/schemas/common/USMCAProduct.yml'


/schemas/common/UsdaSc6.yml:
Expand Down