Recent

Author Topic: Building a REST API - REST Dataware  (Read 1012 times)

Donoss

  • New Member
  • *
  • Posts: 18
Building a REST API - REST Dataware
« on: June 15, 2020, 09:08:06 pm »
Hi,

I'm trying to find the best tools to build a simple REST API using JSON and persisting it to a database.  I've looked all over but as a newbie I'm struggling to get started.  I've looked at REST Dataware but when I try to build a simple module I get an issue 'Can't find unit udmservice'.

I wanted to look at SQLDBRESTBridge but can't find the package to get it loaded, so any pointers will be really appreciated.

I also looked at Brook, lots of documentation but I'm new to this so got lost easily.

I also tried Mormot but can't get the packages loaded either direct or using the online package manager.

Any pointer to an easy example or component set for a very simple REST API will be much appreciated.

Many thanks

Andy

simone

  • Sr. Member
  • ****
  • Posts: 358
Re: Building a REST API - REST Dataware
« Reply #1 on: June 15, 2020, 09:31:27 pm »
Microsoft Windows 10 64 bit - Lazarus 2.0.10

PascalDragon

  • Hero Member
  • *****
  • Posts: 2262
  • Compiler Developer
Re: Building a REST API - REST Dataware
« Reply #2 on: June 16, 2020, 10:18:29 am »
I wanted to look at SQLDBRESTBridge but can't find the package to get it loaded, so any pointers will be really appreciated.

You need FPC 3.2.0 or newer for that. You can use the RC1 for this.

Donoss

  • New Member
  • *
  • Posts: 18
Re: Building a REST API - REST Dataware
« Reply #3 on: June 16, 2020, 02:51:00 pm »
Hi everyone thanks for the info.

PascalDragon I assume you mean't 3.0.2 above for FPC?   Also the link doesn't appear to work, does it take you to the FPC download page?

Thanks

Andy

PascalDragon

  • Hero Member
  • *****
  • Posts: 2262
  • Compiler Developer
Re: Building a REST API - REST Dataware
« Reply #4 on: June 16, 2020, 03:29:59 pm »
PascalDragon I assume you mean't 3.0.2 above for FPC?   Also the link doesn't appear to work, does it take you to the FPC download page?

No, I meant 3.2.0, the upcoming release which is currently being finished and for which a release candidate is provided on the linked page (and the link works for me, but just in case: you need to go to the "Announcements -> Free Pascal" subforum at the top of the forum lists and then there is the thread "FPC 3.2.0rc1 released!"; the first post contains links to the downloads).

Donoss

  • New Member
  • *
  • Posts: 18
Re: Building a REST API - REST Dataware
« Reply #5 on: June 21, 2020, 11:35:38 am »
Thanks @PascalDragon got it ....

PascalDragon

  • Hero Member
  • *****
  • Posts: 2262
  • Compiler Developer
Re: Building a REST API - REST Dataware
« Reply #6 on: June 21, 2020, 02:36:59 pm »
And by now the final release is available as well. ;)

wisheskernel

  • New member
  • *
  • Posts: 6
Re: Building a REST API - REST Dataware
« Reply #7 on: September 22, 2020, 12:14:07 pm »
My environment: Windows7 64bit, FPC 3.0.4, Lazarus 2.0.0  x86_64 and
I got the Compile error : Can't determine which overloaded function to call , at

Code: Pascal  [Select][+][-]
  1. DWClientREST1.Get;  //DWClientREST1: TDWClientREST;

Any help is going to be appreciated.

nummer8

  • Jr. Member
  • **
  • Posts: 57
Re: Building a REST API - REST Dataware
« Reply #8 on: September 22, 2020, 01:00:43 pm »
Marcus Fernstrom posted two example video's on youtube

Create REST APIs in FreePascal & Lazarus
https://www.youtube.com/watch?v=9N0cxI1Hp0U

Create REST APIs in FreePascal & Lazarus (with zoom)
https://www.youtube.com/watch?v=rEqVnwE8_Us

 

TinyPortal © 2005-2018