A thought on a mix of this, just to put it out there. Only really applies if Influx v2 and OSS instances always default their endpoints to the
You could have the
/api/v2/ appear as text off the end of the server URL text field, and as long as the text entered in the field doesn’t end with a slash then you append that to the end of the ip:port that is in the field.
If the URL ends in a slash, then hide the
/api/v2/ from the right side of the text field and use the URL exactly as it was entered.
Might be over complicating it, but I thought it would be a nice way to support folks who are using things basically as defaults, who would benefit from the auto-appending, while providing a easy way for users who have customised their influx instance and know they’ll need to do that. The text on the right side of the text field gives a subtle but clear indication of when the URL is being appended or not that way too.
And it would still work for when the
/api/v2/ is on the end of a longer URL, more than just an IP:port or domain name, but even if the base URL was something like
https://domain.name/influx since leaving the slash off the end of the
influx in the base URL would still append the
Anyway, I don’t know if that would be overkill, but I feel like it would be just smart enough to help user’s just getting into it all, while not being so “smart” that it would annoy user’s who most experienced in it all.