Endpoint slug conflict when using different versions

Hi Apidog Team,

We are maintaining two versions of our APIs in our published API documentation site: v1 and v2.
While setting up release versions, I used slugs v1 and v2. Because of this, my base URLs are now:

v2 → https://{custom-domain}/v1/
v2-legacy → https://{custom-domain}/v2/

My endpoints are the same in both versions, so I want to keep the same endpoint slug (for example /get-my-agent) under both versions

But Apidog shows the error: “Same URL already exists, please modify”, even though the base URLs are different.

Since the endpoints are identical in both versions, I need the endpoint slugs to remain the same. Could you please confirm if this is a bug or guide us on the correct way to achieve this?

Thanks.

Hi Hamza,

Did you create and maintain both versions of the APIs as separate endpoints in the main branch? For cases like this where you have identical endpoints across versions, we recommend creating API versions based on the main branch in Apidog.

You can modify the endpoints in the version branches, and related endpoints will automatically share the same slug by default. Please refer to this documentation for more details: API Versions in Apidog - Apidog Docs

I have a couple of questions on API Versions:

  1. Is it possible to switch under Publish Docs Site → Release which version is the default on (i.e. which version is selected by default on Release drop down on the site? Currently, it looks like only the first version can be the default.

  2. Say I have a v1 and v2 for API version; with the v1 being the original one associated with the main (default) branch created at account setup. Is there a way to merge changes to the main branch for the V1 to the branch used for V2 (I presume there is some branch behind the V2 as well).

  3. It looks like the sprint batches can only be used to merge into the original main branch (associated with V1). Is it possible to have sprint batches created off from the V2 branch as well? And merge into them into the V2 branch?

Hi Hamza,

  1. You can reorder the version list - the first version in the list will be set as default. Publish API versions - Apidog Docs
  2. API versions are independent and won’t affect each other. Create API versions - Apidog Docs
  3. Currently, creating sprint branches from V2 branch isn’t supported. Our recommended practice is to keep operations within a branch isolated from main/other branches.Design API in a branch - Apidog Docs

Hi Hamza,

Apologies for the confusion earlier. Currently, you can specify the default version displayed on the docs site by modifying the release source of the version. We’ve noted that the related help documentation needs updating, and we’ll revise it promptly. Sorry for any inconvenience caused.

Sound good. Thank you.