--- title: "Get Predictions v2" slug: "get-predictions-v2" updated: 2024-12-11T15:47:45Z published: 2026-03-16T14:44:43Z canonical: "docs.xgen.ai/get-predictions-v2" --- > ## Documentation Index > Fetch the complete documentation index at: https://docs.xgen.ai/llms.txt > Use this file to discover all available pages before exploring further. # Get Predictions v2 Post/v2/render/customers/{customerId}/users/{userId} SecurityAPI Key: AccessTokenAuthHeader parameter nameaccess_token Access token Authentication Path parameterscustomerIdstringRequired userIdstringRequired Body parametersExpand Allobject contextobject (Context) the context object used for dynamic data excludestring Context used to exclude specific items by id Example123|456|789 pathnamestring The pathname of the page Example/en-us/men/shirts queryStringstring The query string of the page Example?color=red&size=large&xse_page=home recentlyViewedstring The recently viewed items Example123|456|789 pdpCodestring The product code of the current PDP page Example123 xt_genderstring Example how to pass dynamic context - The dynamic gender context Examplefemale element_ids Array of string The element ids to get predictions for Example[ "sm_el_1234", "sm_el_5678" ]string Responses200 Successful response Expand Allobject render_data Array of object the render data object object elementobject the element details idstring the element id Examplesm_el_1234 rulesetobject the ruleset object exceptionstring The exception rule Examplext_gender == "female" excludestring The exclude rule Examplext_gender != "female" prediction Array of object (Product) The predictions array object brandstring ExampleYour brand colorstring ExampleGreen currencystring ExampleUSD currency_symbolstring Example$ custom_string_1string Examplesome string 1 custom_string_2string Examplesome string 2 custom_string_3string Examplesome string 3 custom_string_4string Examplesome string 4 custom_string_5string Examplesome string 5 genderstring Examplefemale imagestring (uri) Examplehttps://www.example.com/image.jpg image_altstring (uri) Examplehttps://www.example.com/image-alt.jpg is_in_stockstring Example1 is_on_salestring Example0 item_typestring Exampleadult macroCategorystring ExampleDresses macroColorstring ExampleOrange microCategorystring ExampleLong Dresses pricenumber (float) Example11500.0 prod_codestring Exampleabc123 prod_namestring ExampleYour Prod Name product_types Array of string Example[ "Woman", "Dresses", "Long Dresses" ]string product_urlstring (uri) Examplehttps://link-to-product.com sale_pricenumber (float) Example11000.0 sizestring Example2 400 Bad request 401 Unauthorized 403 Forbidden 500 Internal server error