Exploring API specifications on the SAP API Business Hub

Поделиться
HTML-код
  • Опубликовано: 2 авг 2024
  • Let's get back to basics and understand & explore API specifications on the SAP API Business Hub.
    Topics:
    CAP, CDS, A2A, A2X, APIs, OData, EDMX, metadata, VS Code, CSDL, annotations, curl
    Links:
    SAP API Business Hub: api.sap.com
    Getting started with SAP API Business Hub: • SAP API Business Hub
    An Overview of the SAP S/4HANA VDM: blog.sap-press.com/an-overvie...
    OData CSDL Modeler extension: marketplace.visualstudio.com/...
    Chapters:
    00:00 Welcome and introduction with some extra rambling about my setup
    05:02 Moving to the SAP API Business Hub
    07:55 Starting to dive into the SAP S/4HANA product
    09:00 Filtering down to the OData V2 APIs and the Business Partner (A2X) API
    10:50 Exploring what the SAP API Business Hub tells us about this API (schema, attrs, spec, extensibility, auth, SAP Cloud SDK support and more)
    15:05 Looking at some of the API endpoints and noticing the OData system query options, plus the classic OData v2 JSON response format (with the 'd' property)
    16:57 Having our first 'try out' of an endpoint directly in the hub, in the sandbox
    22:30 Understanding what the A_ prefix represents in the entity set names
    23:50 Downloading and looking briefly at all the API specification documents (JSON, YAML and EDMX)
    25:55 Fixing my neovim installation that I broke just before the live stream started
    27:30 Staring at and exploring the EDMX (the OData service metadata document) for API_BUSINESS_PARTNER
    32:31 Resorting to using Latin to convey what I'm trying to say #FAIL
    34:10 Opening the API_BUSINESS_PARTNER.edmx file in VS Code
    34:30 A great discussion on singular vs plural naming convention for entities
    37:05 Opening the API_BUSINESS_PARTNER.edmx file with the OData CSDL Modeler extension - very diagram, much graphical, wow!
    40:30 Kicking the tyres of the API from my own machine, with curl, working through the responses with an API key (401, then 307, and ultimately a binary gzipped payload)
    48:10 Distinguishing between the service document and the metadata document - the two "well known" documents of any OData service
    50:20 Recognizing the origins of OData in the Atom syndication format XML elements
    53:50 Fixing the name of the entity set we are reminded of the A2X nature of this API by the myriad annotations in the metadata
    55:25 Importing the API_BUSINESS_PARTNER.edmx file into a new CAP (Node.js) project and having it mocked and served locally (as an OData v4 service) with our very own test data, with just one command and in only a couple of minutes!
  • НаукаНаука

Комментарии • 3

  • @kaderaziz7555
    @kaderaziz7555 Год назад

    Okay 😊

  • @wiseskeshom4673
    @wiseskeshom4673 Год назад +1

    Just for anyone who want to follow the CDS part, node V16.x didn't work for me, the API_BUSINESS_PARTNER.csn file was not generated after executed command cds import. However, everything works fine with Node 19. I have not tested with V18.x yet but I guess it should be okay.

  • @Nikhilgupta-lk8ib
    @Nikhilgupta-lk8ib 3 месяца назад

    Can we have implement $search on this API Business partner I need to have a live search when the user starts entering the customer number currently when calling from CAP BTP V4 I get error in backend Invalid query specific parameter