Skip to content

Conversation

FloThinksPi
Copy link
Member

@FloThinksPi FloThinksPi commented Jul 23, 2025

Just as a side note this was already briefly discussed in the App Runtime Interfaces WG and had positive feedback that something like that is thinkable for the WG

Link for easy viewing

@beyhan beyhan requested review from a team, rkoster, beyhan, Gerg, stephanme and cweibel and removed request for a team July 23, 2025 08:53
@beyhan beyhan added toc rfc CFF community RFC labels Jul 23, 2025
@FloThinksPi FloThinksPi changed the title [RFC] Document CF API with OpenAPI [RFC] Document CF API V3 with OpenAPI Jul 23, 2025
@beyhan beyhan moved this from Inbox to In Progress in CF Community Jul 29, 2025
- [AI Agents](https://github.com/janwilmake/openapi-mcp-server) for improved integration with AI-powered tools.

### Phases

Copy link
Contributor

@Samze Samze Jul 30, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thought https://github.com/rswag/rswag would be an interesting approach, create request specs that can be used to generate open api spec. That way we get a open api doc and some verification in a single definition. However that would mean creating/updating whole bunch of requests specs.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I tried that before the issue with that is that we dont use native rails - e.g. we dont use active records but sequel library for the models. Rswag just worked for me when its a absolute default ruby project. But i also like to give it a shot again since i last tried it 1-2 years ago. Optimally we could use something like that but in any case writing the OpenAPI spec by hand is already an improvement from writing the HTML/MD page oneself i guess. Especially for the consumer side the format is the only thing that matters. How its produced is secondary for a CF consumer, relevant for the Working Group though.

@Samze
Copy link
Contributor

Samze commented Jul 30, 2025

From a Broadcom side we're interested in helping with this effort and maintaining an OpenAPI spec for CAPI.

FloThinksPi added a commit to FloThinksPi-Forks/community that referenced this pull request Jul 31, 2025
Copy link
Member

@stephanme stephanme left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Another point to think about: how to continue with the existing CF client libs: cf-java-client and go-cfclient?

Do we maintain multiple client libs? The existing ones for compatibility and the potentially new ones that are (partly) generated from the OpenAPI spec.

The existing ones provide additional value on top of the pure language bindings:

  • authentication support and token refresh
  • pagination handling
  • slicing long guid lists into chunks that fit into urls
  • higher level operations (cf-java-client has an operations api but only for v2)
  • integration of additional api endpoints like loggregator

This goes probably beyond this RFC. The spec clearly helps to get a language binding for the CF API from scratch which is good if no library exists yet or is hopelessly outdated. But if usable client libs exist (java, golang, also python), it becomes a longer way.

beyhan added a commit that referenced this pull request Aug 1, 2025
Copy link
Member

@beyhan beyhan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would suggest following improvements in the RFC:

  • The RFC should explicitly state that the ARI WG will be impacted by this initiative and will need to invest into this effort.
  • The checkpoint phase should additionally define that the OpenAPI effort should be stopped if the expected spec quality can't be implemented.
  • It could include a Future Improvements section that outlines potential benefits beyond initial implementation like SDK generation which could be adopted by existing CF clients and make clear that this is out of scope for this RFC.

@FloThinksPi
Copy link
Member Author

Another point to think about: how to continue with the existing CF client libs: cf-java-client and go-cfclient?

Do we maintain multiple client libs? The existing ones for compatibility and the potentially new ones that are (partly) generated from the OpenAPI spec.

The existing ones provide additional value on top of the pure language bindings:

  • authentication support and token refresh
  • pagination handling
  • slicing long guid lists into chunks that fit into urls
  • higher level operations (cf-java-client has an operations api but only for v2)
  • integration of additional api endpoints like loggregator

This goes probably beyond this RFC. The spec clearly helps to get a language binding for the CF API from scratch which is good if no library exists yet or is hopelessly outdated. But if usable client libs exist (java, golang, also python), it becomes a longer way.

Yea i considerd this in the draft for the RFC but removed it since it bloats it up quite a lot. I think its good to keep that in mind as follow up of this RFC.

@FloThinksPi
Copy link
Member Author

I made some adoptions and worked in @beyhan and @stephanme comments.

@stephanme
Copy link
Member

We start the FCP with the goal to accept this RFC on the TOC meeting on 2.9.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
rfc CFF community RFC toc
Projects
Status: In Progress
Development

Successfully merging this pull request may close these issues.

5 participants