Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Automatic inferred dependencies not working #880

Open
ThorIrgens opened this issue Mar 27, 2024 · 0 comments
Open

Automatic inferred dependencies not working #880

ThorIrgens opened this issue Mar 27, 2024 · 0 comments

Comments

@ThorIrgens
Copy link

Description

Hi all.
I am very new to RESTler but have run into a problem that which neither documentation, videos or AI have been able to resolve. It is about automatic inferring dependency between endpoints, like a login and the token it provides.
In my swagger.json I have these paths
"/Login": {
"post": {
"tags": [
"Person"
],
"responses": {
"200": {
"description": "Success",
"content": {
"text/plain": {
"schema": {
"type": "string"
}
}
}
}
}
}
},
"/Person/{allowed}": {
"post": {
"tags": [
"Person"
],
"parameters": [
{
"name": "allowed",
"in": "path",
"required": true,
"schema": {
"type": "string"
}
}
],
"requestBody": {
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/Person"
}
},
"text/json": {
"schema": {
"$ref": "#/components/schemas/Person"
}
},
"application/*+json": {
"schema": {
"$ref": "#/components/schemas/Person"
}
}
}
},
"responses": {
"200": {
"description": "Success",
"content": {
"text/plain": {
"schema": {
"type": "integer",
"format": "int32"
}
},
"application/json": {
"schema": {
"type": "integer",
"format": "int32"
}
},
"text/json": {
"schema": {
"type": "integer",
"format": "int32"
}
}
}
}
}
}
As far as I have been able to read and been told (mainly by Bing AI), this setup should automatically create a dependency between the 2 endpoints, so before calling Person/{allowed}, it would call /Login and use the response as the value for {allowed}. But it always ends up calling Person first and use "fuzzstring" as value for {allowed}.
Anyone have some good pointers?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant