diff --git a/doc/example-clients/example-clients.md b/doc/example-clients/example-clients.md index 3e231f944afe8bb653662726015a42d187353d4b..d93316d76f14ce38e550644b39c9256291ec52cd 100644 --- a/doc/example-clients/example-clients.md +++ b/doc/example-clients/example-clients.md @@ -1,18 +1,57 @@ -# Invoker and Provider CLI -The Invoker and provider CLIs serve as examples for developers and integrators looking to connect their Network Applications (NetApps) to CAPIF. They demonstrate, using Python, how to develop the necessary code for seamless communication with CAPIF, offering a practical guide to implementing the required API calls and interactions. +# Invoker and Provider CLIs +The Invoker and Provider CLIs serve as examples for developers and integrators looking to connect their Network Applications (NetApps) to CAPIF. + +They demonstrate, using Python, how to develop the necessary code for seamless communication with CAPIF, offering a practical guide to implementing the required API calls and interactions. ## Provider CLI -When using the Provider Console, users can create a provider entity that registers and publishes APIs to make them available within the CAPIF ecosystem. This process begins with user registration, where a unique user account is associated with the provider. Once registered, the user gains the ability to define and expose APIs, specifying the necessary details and configurations to allow other clients to discover and interact with them. +When using the Provider Console, users can create a provider entity that registers and publishes APIs to make them available within the CAPIF ecosystem. + +With the provider console you can make the following requests to CAPIF: + +- provider_get_auth - to request the token and CA cert to be able to perform the onboarding +- register_provider - to perform the onboarding of a provider +- publish_service - to publish an api as a provider +- get_services - to see what services the provider has published +- register_events - to register for events +- remove_service - to unpublish an api +- remove_provider - to remove the provider + +Apart from these operations, with the provider console you can also perform operations as administrator if you have a CAPIF locally: + +- login_admin - to obtain the tokens needed to perform admin operations +- refresh_admin - to refresh the admin token +- register_user - to create a user in CAPIF +- remove_user - to delete a CAPIF user + +Additionally, it also contains an API example that contains everything needed to verify the token used by invokers in API requests. Check [Provider CLI](https://labs.etsi.org/rep/ocf/example-clients/provider-cli) for further information. ## Invoker CLI -The Invoker Console complements this by offering tools to explore and consume the APIs registered by providers. An invoker can perform a discovery request, a critical step that enables browsing available APIs in CAPIF. This feature ensures that consumers can find the services they need based on specific criteria or search parameters. After discovering an API, the next step is to establish a secure communication channel. The console allows users to request the creation of a security context, providing the necessary token that authorizes API consumption. This security framework ensures that interactions comply with OpenCAPIF’s authentication and authorization protocols. +Using the Invoker console, users can create their own invoker to discover the APIs published in CAPIF and perform all the necessary actions to be able to consume them. -Check [Invoker CLI](https://labs.etsi.org/rep/ocf/example-clients/provider-cli) for further information. +With the Invoker console you can make the following requests to CAPIF: + +- get_auth - to request the token and CA cert to be able to perform the onboarding +- register_invoker - to perform the onboarding of an invoker +- discover_service - to discover the APIs published in CAPIF +- register_security_context - to make the request to create a security context +- get_security_auth - to request the token necessary for the consumption of an API +- call_service - to consume an api +- register_events - to register for events +- remove_security_context - to delete the created security context +- remove_invoker - to remove the invoker + +Apart from these operations, with the invoker console you can also perform operations as administrator if you have a CAPIF locally: -## Other console features -Beyond the core functionalities of API publication and consumption, the consoles include advanced management options to enhance the user experience and provide comprehensive control over API lifecycles. Users can unpublish APIs when they are no longer needed, effectively removing them from discovery and usage. Furthermore, the consoles support deleting both providers and invokers, offering flexibility in maintaining a clean and organized service architecture. For enhanced adaptability, the system also includes subscription capabilities, enabling users to subscribe to events and receive notifications about changes or updates related to specific APIs. +- login_admin - to obtain the tokens needed to perform admin operations +- refresh_admin - to refresh the admin token +- register_user - to create a user in CAPIF +- remove_user - to delete a CAPIF user + +With these requests you can easily perform the basic flow as a CAPIF Invoker + +Check [Invoker CLI](https://labs.etsi.org/rep/ocf/example-clients/provider-cli) for further information. [OCF Web]: https://ocf.etsi.org/ "OCF Web" [OCF Documentation]: https://ocf.etsi.org/documentation/ "OCF Documentation"