Endpoint for Owner ID
It would be nice to have an endpoint to get the cleartext name of an owners´s ID.
Hi Helmut, thanks for your inpu. Would you like to elaborate by describing your preferred scenario or use case for this requirement ?
#poke
don't know if it will help you. but if you get the content as a string (like here ) you can use this code to get every values from the endpoint separated:
// Ask if the container is found in dataBase
if (bicData.ReasonPhrase == "OK")
{
// Get content as string
var containerDataString = await bicData.Content.ReadAsStringAsync();
// Get a list of JObjects out of the content string
IEnumerable<JObject> objs = JsonConvert.DeserializeObject<List<JObject>>(containerDataString);
// Select the first JObject of the list
JObject containerDataJObject = objs.FirstOrDefault();
// Assign values as string
var tareKg = containerDataJObject["tare_kg"].Value<string>();
var tareLb = containerDataJObject["tare_lbs"].Value<string>();
var netKg = containerDataJObject["max_payload_kg"].Value<string>();
var netLb = containerDataJObject["max_payload_lbs"].Value<string>();
var maxKg = containerDataJObject["max_gross_mass_kg"].Value<string>();
var maxLb = containerDataJObject["max_gross_mass_lbs"].Value<string>();
var cubicM = containerDataJObject["cubic_capacity_cbm"].Value<string>();
var cubicFt = containerDataJObject["cubic_capacity_cuft"].Value<string>();
// And so on...
}
You get the full list of objects in the Swagger example.
Thanks Thorsten. Clearly, that's the idea and a quick way to deserialize the JSON container data.
@1linux , what is your use case to retrive the ownerId of the container ? Are you looking for information about the uploader ? The company which owns the container ? Other ?
@1linux im closing this issue due to the time, but if you need help please open a new issue and we will support you with this, the data you want is in the API.