Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Create Robust REST API for C5 #4708

Closed
ryantfowler opened this issue Nov 23, 2016 · 17 comments
Closed

Create Robust REST API for C5 #4708

ryantfowler opened this issue Nov 23, 2016 · 17 comments

Comments

@ryantfowler
Copy link

@ryantfowler ryantfowler commented Nov 23, 2016

At the encouragement of @KorvinSzanto I am creating this issue to facilitate a plan for the creation of a robust API for this project.

Justification: By creating an API integration with C5 can be much more flexible. For instance, having a "headless" web application allows for various clients to consume the content in whatever way is needed.

What's next? Plan of action!

@mlocati
Copy link
Contributor

@mlocati mlocati commented Nov 23, 2016

@ryantfowler I may be wrong, but... are you referring to a REST api?

@ahukkanen
Copy link
Contributor

@ahukkanen ahukkanen commented Nov 23, 2016

@mlocati I can answer on his behalf and yes, he means that.

I think this would be beneficial.

At least for the express entities and other "strict" objects in the database. It's a little bit tough to see how to make the page content/blocks easily available through API since it can contain quite a lot layout specific information (like areas, layout structures, etc.) but also not sure if that needed.

@ryantfowler
Copy link
Author

@ryantfowler ryantfowler commented Nov 23, 2016

@mlocati Yes, of course a REST api. Using a resource like this as a reference.

@ahukkanen I think it would as well. I too am not sure how much can be made available, but that's what this is for, to discuss what could be made available and how to go about doing so.

@mlocati
Copy link
Contributor

@mlocati mlocati commented Nov 23, 2016

@mlocati Yes, of course a REST api. Using a resource like this as a reference.

@ryantfowler So, what about adding REST to the subject of this issue? I mean, concrete5 already offers a fantastic API, what you're asking here is a REST API...

@aembler aembler changed the title Create Robust API for C5 Create Robust REST API for C5 Nov 23, 2016
@aembler
Copy link
Member

@aembler aembler commented Nov 23, 2016

Agreed REST should be specified to keep this subject on topic.

@ryantfowler
Copy link
Author

@ryantfowler ryantfowler commented Nov 23, 2016

@mlocati Ok, fair enough. That was an oversight on my part.

@hissy
Copy link
Contributor

@hissy hissy commented Nov 23, 2016

Thanks @ryantfowler !
Here is the list what I want in c5 rest api

  • How to extend rest endpoint easily #4722
  • Authorization
  • Built-in Endpoints
    • CRUD for Basic Entity (Page, File, User, Site, Attribute?, Block?)
    • Get Page Type Composer Form Layout as JSON
    • Post new page
    • CRUD for Express Entry
    • Get form fields of Express Entity as JSON
@Hypocrite
Copy link
Contributor

@Hypocrite Hypocrite commented Dec 6, 2016

+1

1 similar comment
@martbase
Copy link

@martbase martbase commented Jan 23, 2017

+1

@ahukkanen
Copy link
Contributor

@ahukkanen ahukkanen commented Mar 21, 2017

I'd also suggest looking at GraphQL as an option for the API. It answers to some of the shortfalls of a pure REST API and also integrates quite seamlessly with React, so it might be useful for many developers.

For example this library could provide the necessary backend functionality:
https://github.com/webonyx/graphql-php

@sharadkap
Copy link

@sharadkap sharadkap commented Oct 3, 2017

Hey guys! Is there any work happening on this? Really keen to see REST API working in C5.

@a3020
Copy link
Contributor

@a3020 a3020 commented Oct 4, 2017

We've released a paid add-on (Centry) for C5 v8.x which provides a small API. It's currently read-only, but it's a nice starting point for agencies / contractors. Usage of the portal is for free, and gives an overview of all the connected C5 instances with some filtering and search possibilities.

@jeffharris23
Copy link

@jeffharris23 jeffharris23 commented Nov 30, 2017

Great to see a discussion about this topic. I think with PWA's gaining tracking and support in iOS for it in the pipeline this kinda functionality will be important. One important feature that comes to mind is support for some kinda JWT authorization.

@aembler
Copy link
Member

@aembler aembler commented Jan 14, 2018

This is currently in progress.

@aembler aembler added this to the 9.0.0 milestone Mar 22, 2018
@ahukkanen
Copy link
Contributor

@ahukkanen ahukkanen commented Nov 7, 2018

Is there any info when we could see some preview for this in the release/9.0.0 branch?

Furthermore, is there any info available regarding the timelines for 9.0.0?

@AntDoesIT
Copy link

@AntDoesIT AntDoesIT commented May 9, 2019

@aembler Trying to get up to speed on this topic... I'm looking at extending the REST API to GET pages and express objects. Is there an update or a roadmap for the REST API features in 9.0.0? Do you have documentation? Do you still need help on adding features to pull common entities (pages, express, etc.)?

@aembler
Copy link
Member

@aembler aembler commented Jun 12, 2019

I think we ought to have people submit proposals as GitHub issues for the REST API.

There is now documentation on how the REST API works, how the routing system works, and how to write a pull request that adds capabilities to the REST API:

https://documentation.concrete5.org/developers/rest-api/adding-functionality-to-the-concrete5-core-rest-api

Let's submit proposals for how things like a comprehensive user, page, etc... endpoint might work.

@aembler aembler closed this Jun 12, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet