Unable to Import Swagger definition using CLI

Hi There,

I am trying to import swagger definition using CLI I am new in the API management, I am using tyk community edition.
When I execute below command I am getting a error as “tyk: error: unknown long flag ‘–import-swagger’, try --help”
[email protected]$:/opt/tyk-gateway$ ./tyk --import-swagger=app.json --create-api --org-id=default --upstream-target=“
tyk: error: unknown long flag ‘–import-swagger’, try --help

can anyone please let me know if I am doing anything wrong

Hello @Rohit_Thakur,

Which version of tyk-gateway are you using?


Hi Zaid

We are using tyk gateway 3.1


Hello @Rohit_Thakur

I am not entirely sure why you’re getting this issue.

Can you please run this command and let me know what you get?

./tyk --create-api --import-swagger=app.json --org-id=default --upstream-target=""