Use the build toolkit
zconbt command to generate the API archive from API projects that are created in
the API toolkit.
About this task
zosConnect-2.0 Applies to zosConnect-2.0.
An API archive (.aar) file contains the information that is needed by IBM z/OS Connect to provide the API. The API project
directories can also be checked in to source control management system and therefore automatically
built and deployed as part of a DevOps pipeline. You can use the build toolkit to build the API projects into deployable archive
files and use scripts to copy the files to the API directory.
Procedure
-
Obtain the latest API source files from your source control management system and put them in a
location that the zconbt command can access.
-
Use the zconbt command to generate the API archive. Use the
--projectDirectory parameter to specify the project directory, and --file
parameter to specify the file name for the generated API archive.
For example:
zconbt --projectDirectory=C:/APIs/purchaseAPI --file=C:/APIs/purchaseAPI.aar
zconbt --projectDirectory=./u/apiProjects/lookupAPI --file=./u/AARs/lookup.aar
Note: If you are running on Microsoft Windows, use either a
double backslash \\ or a forward slash character / in the
path name.
Note: If you are running on z/OS, you can use the sample JCL
provided in <hlq>.SBAQSAMP(BAQZCBT) to run the
zconbt.zos command. You must customize the sample JCL following the
instructions in BAQZCBT.
-
If any errors occur, make the necessary corrections and repeat the procedure.
-
You can now deploy the API archive file by copying it to the designated API directory.
Results
An API is automatically deployed when the API archive is copied into the API directory if
the server is configured to monitor the API directory for changes.
What to do next
For more information about API archive management, see Automated API management.