PaloAltoNetworks / PaloAltoNetworks/docusaurus-openapi-docs
When adding a ":" symbol in the URL, an error occurs during the request
@blindaa121 is already working on this.
Since Apr 1, 2024.
- Dominant language
- TypeScript
- Stars
- 1.1k
- Forks
- 315
- Avg merge
- 7d 5h
- Merged PRs (30d)
- 7
Description
Documentation link
buildPostmanRequest Github Docs
//buildPostmanRequest.ts
function setPathParams(postman: sdk.Request, queryParams: Param[]) {
const source = queryParams.map((param) => {
return new sdk.Variable({
key: param.name,
value: param.value || `:${param.name}`,
});
});
postman.url.variables.assimilate(source, false);
}
yaml
paths:
/User/{id}/page:get:
parameters:
- name: id
in: path
description:
required: true
schema:
type: string
format: 9527
baseUrl: https://api.user.server ↗
path: /User/{id}/page:get
Compiled path: /User/:id/page:get
The variable {id} has been transformed to ":id" and the constant ":get" to a similar format, where "id" is a variable and ":get" is a fixed parameter.
Assuming the id is 9527,
When clicking "Send API Request",
The desired outcome is:
https://api.user.server/User/:9527/page:get
However, the current result is:
https://api.user.server/
The path content is missing.
I would like to add ":" in the path to support filling without the need for "/" and ensure normal request functionality.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.