-
Notifications
You must be signed in to change notification settings - Fork 339
Description
Some legacy services require routes to not be prefixed with the / character. In example an operation with @route("?restype=container") should yield the following request uri: https://myuri/test-container-d1401e73-0567-7e68-91e8-2105f4d5001b?restype=container instead of https://myuri/test-container-d1401e73-0567-7e68-91e8-2105f4d5001b/?restype=container. The / is added by default by typespec to all routes.
We should add a new clientOption to override this behavior. When enabled, it will strip the / character from any prefixed path string.
Example usage on a client:
@@clientOption(Storage.Blob, "includeRootSlash", false, "csharp");
Example usage on an operation:
@@clientOption(Storage.Blob.foo, "includeRootSlash", false, "csharp");
Support for this option should be added for clients, sub-clients / interfaces, and operations. Sub-clients + operations should be able to override the option set by their parent.