#cdubs44

1 messages · Page 1 of 1 (latest)

hoary veldtBOT
dull dust
#

var options = new ProductSearchOptions
{
Query = "active:'true' AND metadata['Page']:'Gymshare Main Payment' AND metadata['State']:'" + state + "'",
};
options.AddExpand("data.default_price");
var service = new ProductService();
var search = service.Search(options);

dapper glade
#

Do you get the results back with the query data?

dull dust
#

State is a variable in the above. It is returning the correct products but yet metadata is null when I send the object to the front-end

#

yes. And it works in TEST mode, but does not work in Prod

#

I just tried to copy a TEST product to live mode, and it worked and came in with the results but again, the metadata shows null

dapper glade
#

Do you mean the product with metadata is returned to your frontend in test mode, but not in live mode?

dull dust
#

Look how metadata says "null"

dapper glade
#

Or do you mean metadata is not returned in your frontend for both test and live mode?

dull dust
#

it works and is shown for test. It does not work for live mode

#

when I switch to test mode, metadata starts to populate

#

See how metadata is now populated? For some reason when I run live mode, it does not populate

#

but the query works correctly so I know the metadata is working and I can see in stripes GUI

dapper glade
#

When you query with Product Search API in live mode, does the metadata return in the response?

#

If so, it's likely somewhere in your server trim the metadata before sending to the frontend

dull dust
#

no it does not

dapper glade
#

Could you share the response directly returned from Stripe? Not the one at frontend

dull dust
#

It is breaking on the line where I try and order it by "Order"

#

and that shows that it's not there even before I send it to the frontend

dapper glade
#

Could you share the full response of service.Search(options)? The search variable

dull dust
#

and why would my server or code not send it in live mode and send it in test mode?

#

like nothing changes other than test mode vs live mode so not sure why that would matter but alright

dapper glade
#

Metadata should be returned, so I'm trying to troubleshoot the raw response from your search to identify what can go wrong

dull dust
#

That is TEST mode

#

now let me send live mode

#

There is live mode

#

No metadata shown at all in live mode yet it's there is test mode

dapper glade
#

This is indeed very strange. I'm checking with my coworker

dull dust
#

oh man, if that's actually what it is, I'm an idiot

dapper glade
dull dust
#

one moment. Let try secret

#

yep, that worked

#

you the man river