Closed cjyabraham closed 5 months ago
API calls needed:
get_projects()
- returns all CNCF projects with all their metadata from landscape for use on all Project listings and charts
get_member_count()
- returns total number of CNCF members for use on the Member count on Who We Are page. If you wanted to create a more generic function, you could return all members with their metadata get_members()
and we can perform the count inside of WordPress.
get_ktps()
- returns all KTPs with all their metadata from landscape for the KTP listing page
To display the latest x end users on the End User page and the platinum members on the Join page, we could possibly use an embed code? It looks like this is already possible for platinum members.
Hi Chris!
Members / End User Supporter
subcategory or Members with enduser: true
? I think we can handle this generically as well either way, as the member concept is generic across landscapes.Given that all of this can be expressed in a generic -not CNCF specific- way, it can be a good opportunity to start building "the landscape API". This API would be just a bunch of pre-generated data files, similar to the ones we already serve on /data/…
to power the web application and the embeddable views, but served from /api/…
. Having them separate will provide a stable interface for consumers to build upon, and will leave us freedom to keep evolving the landscape as needed without having to worry about breaking integrations.
We can discuss this a bit more on Monday during our chat and if it looks good we should be able to get it done next week 🙂
The generic solution sounds great if it works here and can apply to other landscapes. Below are the metadata we use for each of the calls, but, of course, it's fine to include additional fields.
Metadata for get_projects()
:
Metadata for get_members()
:
For get_ktps()
:
For end users, I think this is when enduser: true
and we need to use the joined
field to find the last x members. We'll need these metadata:
I've changed the Platinum Members listing to an embed.
Cool, thanks 👍
Hi!
We've just deployed a first version of the landscape2 API. The following endpoints should cover what you need:
There are some more, like one for getting all members, or specific endpoints for each category and subcategory.
Some notes:
all.json
) can potentially return the same set of fields, but this will vary depending on the information available for each of the items. You can see a full list of fields here.primary
flag.Please let me know if you have any question 🙂
The CNCF site has been updated to use this new API.
The current CNCF site imports data from the CNCF Landscape in the following places. Each will need an equivalent connection to landscape2.
We import all projects for showing on the projects carousel on homepage and various Projects listings. We use these calls:
Member count on Who We Are page generated with this call:
We display the latest end users on the End User page with this call:
We display the platinum members on the Join page with this call:
We import and list KTPs on the KTP listing with these calls