Need advice about which tool to choose?Ask the StackShare community!

API Platform

84
126
+ 1
8
Symfony

8K
5.9K
+ 1
1.1K
Add tool

API Platform vs Symfony: What are the differences?

API Platform is a powerful set of tools built on top of Symfony, a popular PHP framework. While Symfony provides a foundation for building web applications, API Platform focuses specifically on creating and managing APIs. This means that API Platform offers additional features and functionality specifically designed for API development.

  1. Architecture: One key difference between API Platform and Symfony is the architecture they follow. Symfony uses a traditional MVC (Model-View-Controller) architecture, where the application is divided into separate layers responsible for handling various aspects of the application. On the other hand, API Platform follows a CQRS (Command Query Responsibility Segregation) and DDD (Domain-Driven Design) architecture. This allows for better separation of concerns and enables the use of specific patterns and concepts specifically tailored for building APIs.

  2. Automatic CRUD operations: API Platform simplifies the process of creating CRUD (Create, Read, Update, Delete) operations by automatically generating them based on the provided entity definitions. With Symfony, you would need to manually define and implement these operations for each entity.

  3. API documentation: API Platform provides built-in tools for automatically generating API documentation, including interactive API documentation using the OpenAPI (formerly known as Swagger) specification. This makes it easier for developers to understand and consume the API without the need for extensive manual documentation. Symfony, on the other hand, does not have built-in support for generating API documentation.

  4. Serialization and normalization: API Platform offers a powerful serialization and normalization system that allows developers to define how entities should be serialized and normalized when exposed through the API. This ensures consistency and flexibility when dealing with data representations. Symfony also has serialization capabilities, but they are not as comprehensive and integrated as in API Platform.

  5. GraphQL support: API Platform provides out-of-the-box support for GraphQL, a query language for APIs. This allows developers to easily expose GraphQL endpoints and benefit from the advantages of this query language, such as reducing over-fetching and under-fetching of data. Symfony does not have native support for GraphQL and would require additional configuration and libraries to implement it.

In Summary, API Platform and Symfony have key differences in their architecture, automatic CRUD operations, API documentation generation, serialization and normalization capabilities, and native support for GraphQL. API Platform focuses specifically on creating and managing APIs, providing additional features and functionality tailored for API development.

Advice on API Platform and Symfony
Needs advice
on
GolangGolangNode.jsNode.js
and
SymfonySymfony

I'm about to begin working on an API, for which I plan to add GraphQL connectivity for processing data. The data processed will mainly be audio files being downloaded/uploaded with some user messaging & authentication.

I don't mind the difficulty in any service since I've used C++ (for data structures & algorithms at least) and would also say I am patient and can learn fairly quickly. My main concerns would be their performance, libraries/community, and job marketability.

Why I'm stuck between these three...

Symfony: I've programmed in PHP for back-end in a previous internship and may do so again in a few months.

Node.js: It's newer than PHP, and it's JavaScript where my front-end stack will be React and (likely) React Native.

Go: It's newer than PHP, I've heard of its good performance, and it would be nice to learn a new (growing) language.

See more
Replies (1)
Max Musing
Founder & CEO at BaseDash · | 6 upvotes · 192.4K views
Recommends
on
Node.jsNode.js
at

Go with Node.js. There's something really satisfying about being able to use a single language across your entire tech stack. Especially once you integrate GraphQL, which is effectively JSON.

Your second best option is Go, but the ecosystem around Node.js is quite a bit stronger. This will play a big factor when you start building functionality like file management, messaging (especially in real-time), and authentication. The libraries and documentation are just stronger for Node.

See more
Get Advice from developers at your company using StackShare Enterprise. Sign up for StackShare Enterprise.
Learn More
Pros of API Platform
Pros of Symfony
  • 1
    Headless
  • 1
    Microframework
  • 1
    Symfony
  • 1
    Open source
  • 1
    Composer
  • 1
    Easy to use
  • 1
    Automated api-docs
  • 1
    Restful
  • 177
    Open source
  • 149
    Php
  • 130
    Community
  • 129
    Dependency injection
  • 122
    Professional
  • 80
    Doctrine
  • 75
    Organized
  • 71
    Modular architecture
  • 47
    Smart programming
  • 45
    Solid
  • 20
    Documentation
  • 15
    LTS releases
  • 10
    Easy to Learn
  • 9
    Decoupled framework components
  • 9
    Robust
  • 8
    Service container
  • 8
    Bundle
  • 8
    Good practices guideline
  • 7
    Simple
  • 7
    Powerful
  • 6
    Flexible

Sign up to add or upvote prosMake informed product decisions

Cons of API Platform
Cons of Symfony
  • 2
    Easy only for easy task like normal crud on entity
  • 10
    Too many dependency
  • 8
    Lot of config files
  • 4
    YMAL
  • 3
    Feature creep
  • 1
    Bloated

Sign up to add or upvote consMake informed product decisions

- No public GitHub repository available -

What is API Platform?

It is a set of tools to build and consume web APIs. You can build a fully-featured hypermedia or GraphQL API in minutes. Leverage its awesome features to develop complex and high performance API-first projects. Extend or override everything you want.

What is Symfony?

It is written with speed and flexibility in mind. It allows developers to build better and easy to maintain websites with PHP..

Need advice about which tool to choose?Ask the StackShare community!

What companies use API Platform?
What companies use Symfony?
See which teams inside your own company are using API Platform or Symfony.
Sign up for StackShare EnterpriseLearn More

Sign up to get full access to all the companiesMake informed product decisions

What tools integrate with API Platform?
What tools integrate with Symfony?

Sign up to get full access to all the tool integrationsMake informed product decisions

What are some alternatives to API Platform and Symfony?
Laravel
It is a web application framework with expressive, elegant syntax. It attempts to take the pain out of development by easing common tasks used in the majority of web projects, such as authentication, routing, sessions, and caching.
Lumen
Laravel Lumen is a stunningly fast PHP micro-framework for building web applications with expressive, elegant syntax. We believe development must be an enjoyable, creative experience to be truly fulfilling. Lumen attempts to take the pain out of development by easing common tasks used in the majority of web projects, such as routing, database abstraction, queueing, and caching.
Slim
Slim is easy to use for both beginners and professionals. Slim favors cleanliness over terseness and common cases over edge cases. Its interface is simple, intuitive, and extensively documented — both online and in the code itself.
Node.js
Node.js uses an event-driven, non-blocking I/O model that makes it lightweight and efficient, perfect for data-intensive real-time applications that run across distributed devices.
Django
Django is a high-level Python Web framework that encourages rapid development and clean, pragmatic design.
See all alternatives