Product Search View Flattened Attributes
  • 5 Minutes to read
  • Dark
    Light

Product Search View Flattened Attributes

  • Dark
    Light

Article summary

You can flatten the payload so it gives you an export-only payload containing a single set of attributes projected from the lens.

To search the product by ID with flattened attibutes, mention the following in the postman and then click Send.

POST

Query Parameters

Expand to see the parameters and description


Parameter  Parameter TypeData TypeAccepted ValuesDescription
vocabularyId
Recommended (Conditionally Optional)
StringGUIDIf a valid companyId is provided, vocabularyId is not Required
companyIdOptionalStringGUIDIf a valid vocabularyId is provided, companyId is not Required
skipCountOptionalInteger>=0; (skipCount+takeCount)<10,000
Used in combination with takeCount to paginate large numbers of product records. Quantity of records to skip before you start taking products. Whatever value is used for the takeCount, add to skipCount for the subsequent call
takeCount
Optional
Integer>= 0; Max: 500
Sets quantity of results to return at one time. Used for parsing large numbers of product records
useLens
RequiredBooleantrue/falseBased on target party id as contained in Post body, will return effective values only includes all values. Defaults to true. Ex. Using a recipient ID with useLens as true will return the product data applicable to that recipient
flattenLensedProductRequiredBooleantrue/falseAllows for flattening search results. Using this parameter you'll get only the recipient overrides.
locale
OptionalenumISO 639-1 standard
Stores the value passed in a language specific variant. Facilitates different values in different langugages on the same attribute. Defaults to en-US.
shouldIncludeMissingVocabularyAttributes
OptionalBooleantrue/false
Will determine if attributes not included in your company vocabulary will be returned in search results. Defaults to setting in customer vocabulary, else defaults to false. If set to true, attributes not in vocabulary will return with its GUID.


You can change the param values of skipCount, takeCount, vocabularyId, useLens, locale, and shouldIncludeMissingVocabularyAttributes according to your requirements.

In order to flatten the payload, use the parameters mentioned below:

useLens = true,
flattenLensedProduct=true

Remember to specify the TargetPartyAlias in the request body!

Headers

Authorization: Specify required Auth Token in the header.

Request Parameters

Expand to see the parameters and description
Parameter  Parameter TypeData TypeAccepted ValuesDescription
TargetPartyAlias
RequiredStringRecipient identifier: GUID or as aliased in customer vocab
Sets the lens through which the product data is returned from search
OrderBy
OptionalString
Attribute GUID (Ex. Product Name, Date Created, etc.).
Sets return results order
Desc
Optional
Booleantrue/false
Determines sort order (ascending or descending).
AttributeFilterOperator
Optional
Boolean Operator
AND/ORDefaults to AND
OnHold
Optional
Boolean
true/false
Determines if the search returns OnHold products or not.
Archived
OptionalBooleantrue/false
Determines if the search returns Archived products or not.
Language
Optional
EnumISO 639-1 standard
Defaults to en-US. Sets the Language to be used for search
DataOwner
RequiredString
GUIDCompany ID GUID
ProductIds
RequiredArray of StringsProduct GUIDsList of Products to be searched
IdentifierAttributes
OptionalArray of Strings
Attribute GUIDsList of identifier types to be searched
Identifiers
Optional
Array of Strings
Identifier stringsRequired if you are using “Identifier Attributes”. Contains the list of identifiers to find.
AttributeExistsFilters
OptionalArray of Strings
Attribute GUIDs
Returns products that has (does not have) desired attribute.
AttributeFilters
Optional
Array of Strings
Attribute GUIDs
Searches the value of attribute defined.
SearchType
Part of AttributeFilters
Enum

Contains - has search val within the attribute value searched

Prefix,  - starts with this search value

Suffix,  - ends with this search value

Fuzzy,   - Similar match (fuzzy, a char might be missing in search value for example)

Search   - exact match for search value


Part of AttributeFilters
DateFilter
Optional
Array of Strings
See example, includes:
Name, Operator, Value, IncludeMissing
Array (see example). Searched date field and defined.
Name
RequiredEnumCreatedDate, RecordDate   LastModifiedDate, DiscontinueDate, ObsolescenceDate, LastPublishedDate
Part of DateFilter
OperatorRequiredEnumLessThan, LessThanOrEqualTo, GreaterThan, GreaterThanOrEqualTo
Part of DateFilter
ValueRequiredStringCommonly acceptable string representation of a date/timePart of DateFilter
IncludeMissingRequiredBooleantrue/falsePart of DateFilter
WorkflowFilters
OptionalArray of Strings
Workflow, Statuses []Contains an array including “Workflow” name and “Statuses” as defined for the customer workflow.
Workflow RequiredStringWorkflow names as aliased in Customer VocabPart of WorkflowFilters
Statuses
RequiredArray of StringsStatuses names as aliased in Customer Vocab
Part of WorkflowFilters
PackagingTypes
Optional
EnumUndefined, BaseUnit, Case, Pallet, Display, Pack, Load, SetPack, MixedModule, MultiPack, PrePack, PrePack_Assortment
Used primarily for GDSN package hierarchy
ExcludeProductIds
Optional
StringProduct GUIDs
List of products to be excluded


Request


{
    "TargetPartyAlias": "2f4ffbfb-ad8a-4e0e-846e-a27c06acc92b",
    "OrderBy": "",
    "Desc": false,
    "AttributeFilterOperator": "And",
    "OnHold": false,
    "Archived": false,
    "Language": "en-US",
    "DataOwner": "{{companyId}}",
    "ProductIds": [
        "cc8b72f4-2199-4c28-846a-3dc705ece7f0"
    ]
}

Response 200 OK


{
    "ErrorMode": "Fail",
    "DefaultLocale": "en-US",
    "ProducingOperationDetails": {
        "TotalHitCount": 1,
        "ResultCount": 1
    },
    "ProductImportData": {
        "ProductsToImport": [
            {
                "ImportMode": "ExportOnly",
                "ProductIdentifierPropertyOverride": "",
                "ProductReferencePropertyOverride": "",
                "ProductIdentifierValue": "cc8b72f4-2199-4c28-846a-3dc705ece7f0",
                "SourceParties": [],
                "TaxonomyNodes": [],
                "CatalogItems": [],
                "PackageType": "Pallet",
                "ImmediateParentDetails": {},
                "RecipientsToLink": [
                    "8f4f0656-254f-4bf0-adaf-64a03b4a7ad6",
                    "Amazon US"
                ],
                "RecipientsRequirementSets": {
                    "8f4f0656-254f-4bf0-adaf-64a03b4a7ad6": [
                        "79d40445-4956-b993-d32a-5a7b76ae2b0a"
                    ],
                    "Amazon US": [
                        "Amazon Listing 2.0"
                    ]
                },
                "ComplexValues": [],
                "NutritionalInformationModule": {
                    "Values": [],
                    "MultiValues": [],
                    "ContainerValues": [],
                    "AssetValues": [],
                    "DocumentValues": [],
                    "IsExplicitNullValue": false
                },
                "LifeCycle": {
                    "CreatedDate": {
                        "Value": "2023-01-24T10:40:13.3941232Z",
                        "Delete": false
                    }
                },
                "AuditInfo": {
                    "CreatedDate": "2023-01-24T10:40:13.3941308Z",
                    "LastModifiedDate": "2023-12-15T12:09:52.3992597Z"
                },
                "Archived": false,
                "Values": [
                    {
                        "Name": "GTIN",
                        "ValuesByLocale": {
                            "en-US": "11117111114534"
                        },
                        "SourceParty": "",
                        "Recipient": "2f4ffbfb-ad8a-4e0e-846e-a27c06acc92b",
                        "Delete": false,
                        "IsExplicitNullValue": false
                    },
                    {
                        "Name": "Product Name",
                        "ValuesByLocale": {
                            "en-US": "Amazon Spaghetti noodles"
                        },
                        "SourceParty": "",
                        "Recipient": "2f4ffbfb-ad8a-4e0e-846e-a27c06acc92b",
                        "Delete": false,
                        "IsExplicitNullValue": false
                    },
                    {
                        "Name": "MFG Name",
                        "ValuesByLocale": {
                            "en-US": "Noodle company"
                        },
                        "SourceParty": "",
                        "Recipient": "2f4ffbfb-ad8a-4e0e-846e-a27c06acc92b",
                        "Delete": false,
                        "IsExplicitNullValue": false
                    },
                    {
                        "Name": "Feature - Benefit Bullet 1",
                        "ValuesByLocale": {
                            "en-US": "Al dente perfection in 9-10 minutes"
                        },
                        "SourceParty": "",
                        "Recipient": "2f4ffbfb-ad8a-4e0e-846e-a27c06acc92b",
                        "Delete": false,
                        "IsExplicitNullValue": false
                    },
                    {
                        "Name": "Feature - Benefit Bullet 2",
                        "ValuesByLocale": {
                            "en-US": "Try with tomato sauce"
                        },
                        "SourceParty": "",
                        "Recipient": "2f4ffbfb-ad8a-4e0e-846e-a27c06acc92b",
                        "Delete": false,
                        "IsExplicitNullValue": false
                    },
                    {
                        "Name": "Short Description",
                        "ValuesByLocale": {
                            "en-US": "Spaghetti pasta that is ready in 10 minutes!"
                        },
                        "SourceParty": "",
                        "Recipient": "2f4ffbfb-ad8a-4e0e-846e-a27c06acc92b",
                        "Delete": false,
                        "IsExplicitNullValue": false
                    },
                    {
                        "Name": "Packaging Level",
                        "ValuesByLocale": {
                            "en-US": "PALLET"
                        },
                        "SourceParty": "",
                        "Recipient": "2f4ffbfb-ad8a-4e0e-846e-a27c06acc92b",
                        "Delete": false,
                        "IsExplicitNullValue": false
                    },
                    {
                        "Name": "UPC",
                        "ValuesByLocale": {
                            "en-US": "123456783225"
                        },
                        "SourceParty": "",
                        "Recipient": "2f4ffbfb-ad8a-4e0e-846e-a27c06acc92b",
                        "Delete": false,
                        "IsExplicitNullValue": false
                    },
                    {
                        "Name": "MFG Brand Name",
                        "ValuesByLocale": {
                            "en-US": "Amazon Brand"
                        },
                        "SourceParty": "",
                        "Recipient": "2f4ffbfb-ad8a-4e0e-846e-a27c06acc92b",
                        "Delete": false,
                        "IsExplicitNullValue": false
                    },
                    {
                        "Name": "Feature - Benefit Bullet 3",
                        "ValuesByLocale": {
                            "en-US": "Without preservatives"
                        },
                        "SourceParty": "",
                        "Recipient": "2f4ffbfb-ad8a-4e0e-846e-a27c06acc92b",
                        "Delete": false,
                        "IsExplicitNullValue": false
                    },
                    {
                        "Name": "Last Successful Amazon 2.0 Listing Submission",
                        "ValuesByLocale": {
                            "en-US": "Amazon last successful submission"
                        },
                        "SourceParty": "",
                        "Recipient": "2f4ffbfb-ad8a-4e0e-846e-a27c06acc92b",
                        "Delete": false,
                        "IsExplicitNullValue": false
                    },
                    {
                        "Name": "External Product ID Type",
                        "ValuesByLocale": {
                            "en-US": "upc"
                        },
                        "SourceParty": "",
                        "Recipient": "2f4ffbfb-ad8a-4e0e-846e-a27c06acc92b",
                        "Delete": false,
                        "IsExplicitNullValue": false
                    },
                    {
                        "Name": "Amazon SKU",
                        "ValuesByLocale": {
                            "en-US": "TEST SKU"
                        },
                        "SourceParty": "",
                        "Recipient": "2f4ffbfb-ad8a-4e0e-846e-a27c06acc92b",
                        "Delete": false,
                        "IsExplicitNullValue": false
                    },
                    {
                        "Name": "Main Product Image",
                        "ValuesByLocale": {
                            "en-US": "b82f5e61-ed30-45fd-9763-c493fef23242"
                        },
                        "SourceParty": "",
                        "Recipient": "2f4ffbfb-ad8a-4e0e-846e-a27c06acc92b",
                        "Delete": false,
                        "IsExplicitNullValue": false
                    }
                ],
                "MultiValues": [],
                "ContainerValues": [],
                "AssetValues": [
                    {
                        "Name": "Main Product Image",
                        "ValuesByLocale": {
                            "en-US": {
                                "Name": "Barilla.png",
                                "Url": "https://assets.uat.syndigo.com/b82f5e61-ed30-45fd-9763-c493fef23242?originalFileName=true",
                                "SourceUrl": "https://assets.uat.syndigo.com/bcbda261-f394-4b36-9056-ebf4e8885a72",
                                "Format": "webp"
                            }
                        },
                        "SourceParty": "",
                        "Recipient": "2f4ffbfb-ad8a-4e0e-846e-a27c06acc92b",
                        "Delete": false,
                        "IsExplicitNullValue": false
                    }
                ],
                "IsExplicitNullValue": false
            }
        ],
        "ProductIdentifierProperty": "",
        "ProductReferenceProperty": "",
        "Archived": false
    }
}


Was this article helpful?

Changing your password will log you out immediately. Use the new password to log back in.
First name must have atleast 2 characters. Numbers and special characters are not allowed.
Last name must have atleast 1 characters. Numbers and special characters are not allowed.
Enter a valid email
Enter a valid password
Your profile has been successfully updated.
ESC

Eddy AI, facilitating knowledge discovery through conversational intelligence