Order_id uniqueness

Hi all, I’m scripting something to look at market data as a way of teaching myself python, and I have a very basic question about the data ESI returns.

When I get something from the markets endpoint, is order_id unique, either absolutely, or by region, type, etc? I was going to use it as a dict key, and don’t want to create any unnecessary problems for myself.

More generally is there a good place for me to have found the answer to this? I looked through the ESI swagger spec, and the developer site a bit, but wasn’t really finding anything specific about it.

Thanks.

Assuming you’re talking about character/corporation market orders endpoint? If so then yes, order_id is a unique value for each specific market order.

He is asking if merging several lists from several regions would result in possibly several order sharing the same order_id (obviously from different regions)

His question is : is the auto_increment key shared among the game , or is there one per region ?

Each order has its own order_id which is globally unique.

you don’t answer the question.

I don’t know how i can get more clear than that.

By answering the two questions I asked in the previous post.

Fixed.

A unique Id returned for an URL is unique among the data returned from that URL .

if I get the resource orders/42 then I know all the order_id in the region are unique, but I have no idea if they can or can’t be found in eg orders/43.
They are globally unique only iff the generator is the same for all the orders from all the regions.

ok then, thank you.

Globally unique in regards to market orders that is, just to be clear.

I.e. one market order would never have the same id as another order. But in theory, a structure/contract id might be the same, however that is quite unlikely to happen.

I thought all the ids were prefixed by the type of the id ?
(that is, the first bits of the id indicate what this id is used for)

Not that I’m aware of. EVE does use ranges to denote what a specific ID could be.

Especially when dealing with location_id

Thanks I figured it was a unique identifier, just wanted to check. Right now it’s not actually character/corp orders, but the markets/{region_id}/orders/ endpoint I’m looking at, but I’m assuming it’s the same order_id no matter what endpoint you’re pulling it from.

Thanks again. :smiley:

Np. Yea no matter where you get the order, if it has the same ID its the same order.

Expect it to be unique, for each pull of the entire order database.

Do not expect it to be unique for all time. There is the potential of the id counter rolling over and restarting. But as the numbers are huge, the chance of an ID clash is nearly zero.

2 Likes

“Unique on a long enough timeline.”
EVE market, and EVE economy as a whole, is a living beast, and it has to shed scales sometimes to grow further.
At every given moment, each order has an unique ID. Just don’t try to merge orders from different years.

Edit: Didn’t see Steve’s reply. My bad.

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.