Announcing Data API Builder (Preview) for PostgreSQL

This post has been republished via RSS; it originally appeared at: Microsoft Tech Community - Latest Blogs - .

Today we are thrilled to announce public preview of Data API Builder.

Data API Builder eliminates much of the complexity to build GraphQL API or REST APIs and provides secure access to your data when using traditional approaches that require significant custom code and extended development time.

With Data API Builder your database objects can be quickly exposed as REST or GraphQL endpoints enabling secure and fast access to your data from any platform, with any language, and using any device. With support for PostgreSQL, Azure SQL, SQL Server, MySQL and Azure Cosmos DB, you have the freedom to select the database technology you prefer - whether it’s a fully managed cloud service such as Azure Database for PostgreSQL or a self-hosted instance of the PostgreSQL engine.

As a developer, boosting your productivity is easy: you can instantly stand up a GraphQL and/or REST endpoint with no code by providing Data API Builder a connection string and basic schema and permissions information in a simple configuration file. This provides your application with the ability to securely perform CRUD operations.

 

GaryHope_0-1678832022858.png

 

Fast data requests with your choice of framework

As a developer you can use the languages and frameworks of your choice to build your apps, whether they’re front frameworks such as Next JS or React, or more traditional frameworks in languages such as Python, PHP, Java or C#. Applications need to be highly responsive more than ever before and Data API Builder helps deliver on that capabilities by providing easy-to-create and fast data access for query, insert, update and delete operations for snappy user experiences. 

Have a look at the Data API Builder Quick Start to get started with Data API Builder and PostgreSQL.

 

Best of both REST and GraphQL endpoints

Data API builder supports both REST and GraphQL and gives you flexibility to choose the type of API that works best for your application and data.

Many developers love GraphQL APIs with their single endpoint and broad range of GraphQL API benefits:

  • Declarative data fetching – define the data structure you want your application to receive and enable clear separation of concerns within the application.
  • No more over fetching and under fetching – applications request exactly what they need and nothing more, helping you save time when fetching data in your application.
  • Strongly typed shema and Introspection – API’s with strongly typed self-documenting schema are less prone to errors as queries can be properly validated.
  • Language agnostic - Developers can build applications using Data API Builder with any platform, any language, and any device of their choice.

 

Accelerate innovation and build on your existing data

Data API Builder gives you the flexibility to build APIs on the data you already have in any of the supported databases outlined above. It does not require you to store your data in any specific service or custom format, providing you with a rich end-to-end developer experience including a CLI client that enables rapid product development and deployment.

 

Built-in fine-grained access control

Data API Builder provides built-in data access authentication and authorization that enables you to securely access your data when using the built-in role-based access control that meets the needs of your application. Data API Builder provides support for AAD managed identify, providing a quick no code authentication configuration option without the need to manage database credentials and connection strings yourself.

 

Out of the box integration with Azure Static Web Apps

Data API Builder is tightly integrated into Azure Static Web Apps, providing the ability to efficiently build dynamic web apps at scale. You can get started building your apps without investing in separate backend development efforts to create APIs for data access. You can focus on writing the code that makes a difference to your users. Data API Builder supports  Azure Database for PostgreSQL- Flexible Server and Azure Database for PostgreSQL - Single Server.

 

GaryHope_1-1678832060244.png

By connecting  your PostgreSQL database to your Static Web Apps resource, you can make REST or GraphQL requests within your frontend client code using the `/data-api` endpoint. CRUD (Create, Read, Update, Delete) requests can also be made to the /data-api/api/<Entity> using the standard POST/GET/PUT/DELETE method headers and the return or request bodies will match your database column headers. You can also make GraphQL queries or mutations to the /data-api/graphql endpoint, using fetch or any GraphQL library you wish.   

 

GaryHope_2-1678832078936.png

 

Azure Static Web Apps additionally provides AAD Managed Identity support for Azure Database for PostgreSQL- Single Server, enabling you to provide a well authenticated API without the complexity of manage credentials and connection strings in your application.

With the preview release of Data API Builder support in Azure Static Web Apps some work remains: We are committed to providing Azure Static Web App support for Azure Cosmos DB for PostgreSQL along with support for Azure Database for PostgreSQL - Flexible Server with AAD managed identity support.

 

Get started!

Check out Data API Builder documentation to get started. For more details on the integration with Azure Static Web Apps see Azure Static Web Apps Database Connections

If you don’t have an Azure subscription, try Azure for free.

We are always eager to hear your feedback so please reach out via email using Ask Azure DB for PostgreSQL. 

Leave a Reply

Your email address will not be published. Required fields are marked *

*

This site uses Akismet to reduce spam. Learn how your comment data is processed.