#barkofdelight

1 messages · Page 1 of 1 (latest)

bright doveBOT
hardy pine
#

I don't remember that being a restriction on the search API. Are you getting errors when you run code with a one or two character substring?

modest sable
#

Here's an example:

len(stripe.Product.search(query='name~"station"').data)
6

len(stripe.Product.search(query='name~"sta"').data)
7
len(stripe.Product.search(query='name~"st"').data)
0

hardy pine
#

Interesting, definitely seems like it is the case. Looking in to this to see if we have it documented as expected behavior

modest sable
#

k thx

hardy pine
#

I have confirmed that it is expected behavior. Not sure why we have this restriction but I will make sure this is publicly documented and will put in a feature request to allow for shorter substrings. It would probably also be helpful for us to explicitly error out rather than silently failing.

modest sable
#

Agreed.

hardy pine
#

Thank you for reporting this, I'm glad I at least know about this restriction now