You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Problem:
Hi, I was wondering if there is any way of disallowing the usage of "/" in the id of nodes. The current format is /. The issue is, that many APIs use the ids as part of the url path.
e.g. /orders/{orderId}
If we want to use that API, this results in /orders/mycollection/123 which usually breaks the api as the slash is interpreted as part of the url path and not as part of the id.
Obviously there are workarounds but they can become quite nasty if many systems are involved.
Is there a way to configure which character the database uses for the ids? If one could configure that the ids should look like - or something like that, it would already help a lot.
The text was updated successfully, but these errors were encountered:
@Kafkalasch : there is no option available to configure the character that is used to separate the collection name part and the key part in ArangoDB document ids. The character is hard-coded to /, and many components in ArangoDB rely on this character. So I think it is safe to assume that it will stay this way for the foreseeable future.
In order to use a document id in URLs, it will need to be URL-encoded, e.g. /orders/mycollection/123 would become /orders/%2f123 or such. This does not only apply to the forward slash, but also to some other punctuation characters which could be used in URLs.
There is also the possibility of doing the replacement of forward slashes with some other character in the client application, and decoding it on the server-side if custom receiving APIs are built on the server side. If the latter is not the case, then it is of course not an option.
My Environment
Problem:
Hi, I was wondering if there is any way of disallowing the usage of "/" in the id of nodes. The current format is /. The issue is, that many APIs use the ids as part of the url path.
e.g.
/orders/{orderId}
If we want to use that API, this results in
/orders/mycollection/123
which usually breaks the api as the slash is interpreted as part of the url path and not as part of the id.Obviously there are workarounds but they can become quite nasty if many systems are involved.
Is there a way to configure which character the database uses for the ids? If one could configure that the ids should look like - or something like that, it would already help a lot.
The text was updated successfully, but these errors were encountered: