Exploring OpenCAPIF Release 2

January 15, 2025

Say hello to OpenCAPIF 2.0.0, our new release, now available on ETSI Labs!

Upgraded to support technical specifications from the 3GPP Common API Framework Release 17 to Release 18 (TS 23.222, TS 29.222, TS 33.122) and the YAML templates available in 3GPP Forge, OpenCAPIF version 2.0.0 introduces significant updates, enhancements, and new features aimed at providing a more robust, secure, and efficient API management platform. Let’s venture into the exciting changes brought by OpenCAPIF 2.0.0!

New Features and Improvements

Alignment with 3GPP CAPIF Release 18

The technical specifications of the 3GPP Common API Framework Release 18 provide new endpoints, new models, and new functionalities across all services. You can check our wiki to learn more about the published changes.

Among other things, this upgrade introduces new operations like PATCH requests in the Invoker Management service, Events service, and Publish service, as well as new functionalities like Vendor Extensibility and API Status features.

Additionally, the supportedFeatures parameter is now mandatory in all POST and PUT requests towards OpenCAPIF, as explained in the technical specifications. This parameter must be present in those requests. The value inside supportedFeatures must be a string of hexadecimal numbers according to the active features; if none are active, you can send just 0.

Vendor Extensibility Feature

The CAPIF specification in 3GPP Release 18 introduces a key feature called Vendor Extensibility, designed to enhance flexibility and customization in API consumption.

It is a mechanism for APIs to reuse and extend their functionalities and data models, and engage with third-party API frameworks.

Vendor Extensibility allows operators and developers to extend the standard capabilities of OpenCAPIF in a controlled manner while adhering to the interoperability rules established by 3GPP. This means vendors can define and register custom API extensions, ensuring seamless integration with standard solutions and making these extensions accessible in a 3GPP-compliant format.

API Status Feature

This new feature is present in the technical specifications of the 3GPP Common API Framework since Release 17, and it is now available in OpenCAPIF Release 2.0.0.

The API Status feature in OpenCAPIF allows operators and developers to know, in real-time, whether an API is working as expected. It helps track the availability of APIs, ensuring users can make better decisions about how to use them.

If the ApiStatusMonitoring supported feature is active when an API is published, it allows indicating which AEFs are ready to expose that published API. This means all entities will have more detailed information about which AEFs are currently available for that API. Additionally, events related to service API availability are more fine-tuned, indicating availability or unavailability according to the AEFs present to expose the API.

CI/CD Improvements

For this new version, CI/CD pipelines have been significantly improved to ensure smoother and more efficient deployment processes.

Sandbox Environment

Coming along this release, ETSI is now providing a new environment to expose a public instance of OpenCAPIF as a sandbox. This sandbox allows developers to test both Release 2.0.0 and 1.0.0 in a controlled setting.

Developers can access the sandbox environment to test and validate their applications against OpenCAPIF by requesting credentials to SDG Support.

Testing Updates

The changes related to testing include:

  • New Vendor Extensibility test suite with 9 tests.
  • New API Status test suite with 20 tests.
  • Improved Events test suite with 8 new tests.
  • Test plan updated with default supported features for all requests set to 0 (all inactive by default).
  • Superadmin certificates are now handled and provide more information to improve checks over test suites by reaching the helper service.

New Tools for Testing & Deployment

Multiple scripts were created to simplify the deployment of OpenCAPIF on a Kubernetes cluster and interact with the deployed instance. All these scripts are configured by settings under the variables.sh file.

  • Deployment Scripts:

    • install_vault.sh: Deploy the Vault component from the Kubernetes cluster, only needed if Vault is not previously deployed. If it’s deployed, you can set up the Vault token in variables.sh.
    • install_monitoring.sh: Deploy monitoring on the Kubernetes cluster.
    • install_capif.sh: Deploy OpenCAPIF on the Kubernetes cluster. It will be deployed on the configured namespace with the domain and hostnames configured under variables.sh.
    • uninstall_vault.sh Rollback the Vault component from the Kubernetes cluster.
    • uninstall_monitoring.sh: Rollback monitoring components from the Kubernetes cluster.
    • uninstall_capif.sh: Rollback OpenCAPIF from the Kubernetes cluster.
  • Manage Remote Users:

    • create_remote_users.sh: This script creates users set up by parameters on the deployed OpenCAPIF. These users are created by the administrator.
    • remove_remote_users.sh: This script removes users from the deployed OpenCAPIF.
    • remove_remote_users_by_prefix.sh: This script removes users by prefix.
  • Configuration of Bastion Machine:

    • get_ingress.sh: This script creates a configuration for DNS fixed resolution for the ingress configured in the namespace passed by parameters.
    • set_ingress.sh: This script adds to /etc/hosts the fixed DNS resolution for the ingress setup for the namespace passed by parameters.
  • Execute Robot Tests Over Remote Deployment:

    • run_remote_capif_tests.sh: This script launches the Robot Test Docker image on the current machine to reach the deployed OpenCAPIF. It is useful to launch with --include smoke to ensure all is deployed properly.
  • For Testing Purposes:

    • populate_create_remote_dummy_users.sh: Create dummy providers and invokers, publish service APIs, and create a security context for invokers.
    • populate_remove_remote_dummy_users.sh: Remove dummy information created.

Invoker and Provider Example Clients

We are making available example Invoker and Provider clients developed for testing purposes. You can find them under the new example-clients repository on ETSI Labs.

Software Development Kit (SDK)

With the aim of simplifying the development of new invokers and providers to interact with OpenCAPIF, a new Python-based SDK is released. This SDK is designed to lower integration complexity and allow developers to focus on Network Applications (Network Apps) or services development. The OpenCAPIF SDK provides a set of libraries to enable either CAPIF provider and invoker roles, simplifying procedures calls towards the OpenCAPIF entity.

Key features of the SDK are:

  • Compatibility: The current version of the OpenCAPIF SDK is compatible with OpenCAPIF Releases 1.0 and 2.0.
  • Ease of Integration: The SDK simplifies the process of connecting to OpenCAPIF, making it easier for developers to build and integrate Network Apps.
  • Comprehensive Documentation: Detailed documentation is available to guide developers through the SDK’s features and functionalities.
  • Easy Installation: THe SDK is available in the Python Package Index (PyPI) using a single command: pip install opencapif_sdk!

You can find further information in our documentation and also in the sdk repository.

Documentation Updates

  • Test Suites for New Features Added: Vendor Extensibility and API Status features test plan are now included in the documentation.
  • Updated Test Plans: In alignment with the implementation improvements, some tests were updated, including example bodies.
  • Postman Section Updated: The Postman section got new flows, and all related files needed to test are now up-to-date.

Technical Debt Solved

  • REDIS Now Ready on Deployment: REDIS scheduled on start to allow receiving notifications since the service is deployed.
  • Multiple APFs on Provider Fixed: Solved the problem of removing service APIs published if the provider registers more than one APF.
  • Fixed Problem Removing Published APIs: Solved the Superadmin problem of deleting service APIs published through the helper service if the provider is not present.
  • More Stability: Increased overall stability by fixing some corner cases.
  • Location Headers Standardization: Location headers are now filled in the same way for all services requiring it.
  • Security Issues Fixed: Security issues detected by scans on the repository are now solved.
  • Docker Base Images: Base Docker images are now present in OpenCAPIF’s container registry on ETSI Labs.
  • Robot Test Image: Robot image are now being uploaded to OpenCAPIF’s container registry on ETSI Labs.
  • Improved Testing: Testing improved to accomplish new requirements of the test plan.
  • Upgraded Local Scripts: Improved scripts for service management and testing.
  • Codebase Improvements: Repository reorganization, code quality enhancements, and removal of obsolete data.

How to Run OpenCAPIF Version 2.0.0

To deploy and test OpenCAPIF 2.0.0, either:

  • clone our public repository and checkout the v2.0.0-release tag; or
  • download the release archive here.

After retrieving the code, refer to the How To Run section in our documentation and the Testing section for instructions on using Postman or the Robot Framework.

Learn More!

For further information, please consult the following links: