Module flatapi

ballerinax/flatapi Ballerina library

1.5.2

Overview

The Flat API v2.13.0 connector(https://flat.io/developers/docs/api/) OpenAPI specification. The Flat API allows you to easily extend the abilities of the Flat Platform. Flat is a powerful cloud-based notation software that let you to create music scores and guitar tabs.

Key Features

  • Programmatic access to create and manage resources via REST API
  • Manage user accounts and profiles
  • Secure authentication with API key or OAuth support

Prerequisites

Before using this connector in your Ballerina application, complete the following:

Quickstart

To use the Flat connector in your Ballerina application, update the .bal file as follows:

Step 1: Import connector

Import the ballerinax/flatapi module into the Ballerina project.

Copy
import ballerinax/flatapi;

Step 2: Create a new connector instance

You can use Personal Access Token(PAT) for authentication:

Copy
flatapi:ClientConfig clientConfig = {
    auth: {
        token: <PAT_TOKEN>
    }
};

flatapi:Client baseClient = check new Client(clientConfig, serviceUrl = "https://api.flat.io/v2");

Step 3: Invoke connector operation

  1. You can get detail about score created.
    Copy
    flatapi:ScoreDetails score = check baseClient->getScore(<SCORE_ID>);
  2. Use bal run command to compile and run the Ballerina program.

Import

import ballerinax/flatapi;Copy

Other versions

See more...

Metadata

Released date: 3 days ago

Version: 1.5.2

License: Apache-2.0


Compatibility

Platform: any

Ballerina version: 2201.8.0

GraalVM compatible: Yes


Pull count

Total: 26

Current verison: 0


Weekly downloads


Source repository


Keywords

Type/Connector

Vendor/Flat

Area/Productivity & Collaboration

Lifestyle & Entertainment/News & Lifestyle

Cost/Freemium


Contributors