Generate API tests with Katalon Studio's AI (beta)
Katalon Studio's AI agent generates and runs API tests from your OpenAPI specification. Review the results, then save the tests you want to keep as Katalon test cases in your project.
- An OpenAPI (Swagger) specification, as a URL or a local file.
- Only header-based authorization is supported. Other mechanisms, such as NTLM or Digest, are not included in the generated tests.
Generate and run API tests​
Refer to the walkthrough video for the full workflow.
-
Import your OpenAPI spec. Go to File > Import > REST request from OpenAPI/Swagger, then enter the URL or browse to the file. Katalon creates an API Collection folder in Object Repository.
-
Open the collection. Double-click the API Collection folder, then select the Generate Test tab.
-
Choose what to test. Select the available options that come from your spec:
- Test Type: Positive, Negative, Security, or Edge Case testing.
- API Path: the endpoints to cover. If you leave this empty, Katalon tests all paths.
- HTTP Method: the methods to include.
-
Generate. Click Generate Test. Katalon generates the tests and runs them. A progress bar shows the status. Click Hide to keep working while it runs in the background.
-
Review the results. A summary shows the total tests, passed, warnings, and errors, broken down by test type. Click View detailed HTML Report to see compliance scores, AI-detected issues, recommendations, and logs.
-
(Optional) Save and rerun. Save the generation configuration so you can rerun it later. Use it to confirm fixes after API changes and compare results across runs without setting everything up again.
-
Generate Katalon test cases. To keep the tests in your project:
- On the results view, click Generate Katalon Test Case.
- In Select Test Cases to Generate, select the tests you want, or click Select All.
- Click OK.
Katalon saves the tests under Test Cases > [Collection name] AI Generated > [Configuration name] > [API path]. If you haven't saved the configuration, Katalon names the folder Auto-saved Configuration [timestamp]. Each test case is a regular Katalon test case, with request, payload, send, and assertion steps. You can edit it, add it to a test suite, and run it like any other test case.