xtrareports-404631-backend-web-api-service-rest-api-for-reporting.md
Your Reporting application may require a report distribution mechanism. A database can store report definitions/templates and users can view or download reports based on permissions. To implement such functionality, you can use DevExpress Web API Service. It allows you to add role-based access control, permission management, and CRUD operations to your next .NET project: DevExpress .NET App Security & Web API Service.
Powered by Entity Framework Core ORM (EF Core)DevExpress Web API Service leverages the functionality of EF Core to implement CRUD operations required for your app.Multiple Authentication StrategiesYou application’s authentication mechanism can leverage built-in support for OAuth2, JWT, and OpenID. You can also implement a custom authentication strategy.Cross-Platform CompatibilityBackend Web API Service is platform-agnostic. You can access reporting functionality from various types of clients – web, mobile, and desktop applications.IDE IntegrationIf you work in Visual Studio 2022+ for Windows, integrated Solution Wizard automatically scaffolds your Web Service to speed up application development.
Basic functionality of DevExpress Web API Service is available for free. Additional capabilities and services listed below are available as part of the DevExpress Universal Subscription:
Start by designing your reports in Visual Studio. Bind these reports to your EF Core data models / entities. Use built-in API to store report templates in a database. You can then use DevExpress Web API Service to allow permission-based access to reports and EF Core entities. For this purpose, the service includes built-in report endpoints that start with api/Report/. These endpoints allow users to specify data filters and download documents in PDF, RTF, and other formats.
The following article describes report query syntax supported by DevExpress Web API service: Obtain a Report from a Web API Controller Endpoint.
Review a few endpoint call examples:
/api/Report/DownloadByName(ReportName)?criteria=[FirstName] = 'Aaron'/api/Report/DownloadByName(ReportName)?sortProperty=[FirstName],Descending/api/Report/DownloadByKey({key})?FirstName=Mary&Position=ManagerRefer to the following articles for additional information:
The following examples use DevExpress Web API Service for user authorization and report access in popular UI frameworks:
View Example: .NET MAUIView Example: Blazor WebAssemblyView Example: JavaScript (Svelte)
See Also