Skip to content

Conversation

@lonnieezell
Copy link
Member

Description
This creates a new "Getting Started with RESTful APIs" guide that steps through using the auto-routing and ResponseTrait, plus the new transformers and API response pagination to create a simple API.

It moves the existing tutorial under a new "Guides" section.

@lonnieezell lonnieezell changed the title Created a new Make an RESTful API guide docs: Created a new Make an RESTful API guide Nov 21, 2025
Copy link
Contributor

@neznaika0 neznaika0 left a comment

Choose a reason for hiding this comment

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

Guides are a great idea. We can discuss on the forum what built-in mechanics are possible using the framework. I tried to tell you about the Validator, but you didn't approve.

I looked it up from phone.

@neznaika0
Copy link
Contributor

You have moved the pages to the directory. Some error correction paths need to be updated.
../outgoing/* >> ../../outgoing/*

Copy link
Member

@michalsn michalsn left a comment

Choose a reason for hiding this comment

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

This looks great - it's a really nice introduction to the topic and a solid guide overall.

As mentioned, there are a few issues with the links (since we reference the tutorial in several places), and some of the images appear to be broken.

The only thing I'm not happy with is the current navigation. Subpages aren't visible in the left menu when you enter a specific guide category, which makes it difficult to move between different parts of the guide. Setting 'navigation_depth': 3 in conf.py should fix this.

Other than that, everything looks very good.

@michalsn michalsn added documentation Pull requests for documentation only 4.7 labels Nov 30, 2025
@paulbalandan paulbalandan changed the title docs: Created a new Make an RESTful API guide docs: Created a new Make a RESTful API guide Jan 31, 2026
@paulbalandan paulbalandan changed the title docs: Created a new Make a RESTful API guide docs: Create a new Make a RESTful API guide Jan 31, 2026
lonnieezell and others added 5 commits January 31, 2026 20:03
Co-authored-by: neznaika0 <ozornick.ks@gmail.com>
Co-authored-by: neznaika0 <ozornick.ks@gmail.com>
Co-authored-by: Pooya Parsa <pooya_parsa_dadashi@yahoo.com>
Co-authored-by: Pooya Parsa <pooya_parsa_dadashi@yahoo.com>
@paulbalandan paulbalandan force-pushed the api-guide branch 3 times, most recently from dc813be to 39a9794 Compare January 31, 2026 14:00
@paulbalandan
Copy link
Member

I have implemented the changes as requested. Please propose changes where necessary.

Comment on lines +79 to +80
Test the list endpoint
--------------------------
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
Test the list endpoint
--------------------------
Test the list endpoint
-----------------------

Comment on lines +12 to +13
Why Auto-Routing?
==================
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
Why Auto-Routing?
==================
Why Auto-Routing?
=============

Copy link
Member

Choose a reason for hiding this comment

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

Is it really shorter?


.. code-block:: console
php spark make:model AuthorModel
Copy link
Contributor

Choose a reason for hiding this comment

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

There is an inconsistency in the model’s table name.
php spark make:model AuthorModel correctly sets the table to authors, which matches CI4 conventions and the existing migrations and seeders.

However, the model currently uses author, causing a mismatch with the database schema. The same issue for Book.

Copy link
Member

Choose a reason for hiding this comment

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

Thanks. I have based thus change from @neznaika0 's comment and referred to fixture models in tests/_support/Models/ using singular table name. I have forgotten that.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

4.7 documentation Pull requests for documentation only

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants