laas

module
v0.0.0-...-a9bc940 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 26, 2023 License: Apache-2.0

README

laas

An API that has database of open source license. It stores the basic information about the license such as short name, long name and url.

Prerequisite

Please install and set-up Golang as well as install and set-up Postman on your system in advance.

How to run this project?

  1. Clone this Project and Navigate to the folder.
https://github.com/k-avy/laas.git
cd laas
  1. Build the project using following command.
go build ./cmd/laas
  1. Run the executable in your vscode terminal.
./laas
  1. You can directly run it by the following command.
go run ./cmd/laas
  1. You can see this work on Postman on your system
    or
    you can use run it on your browser using link:
localhost:8080/licenses

Features

  1. You can get the data of all licenses in the database using the following link in browser:
localhost:8080/licenses
  1. You can post the data of the license in the database using following command in your terminal:
 curl -X POST localhost:8080/licenses -H "Content-Type: application/json" -d '{ "shortname":"LGPL-3.0-or-later","longname":"GNU Lesser General Public License v3.0 or later","url": "https:\/\/www.gnu.org\/licenses\/lgpl-3.0-standalone.html"}'
  1. You can also get information of a single license using following link in your browser:
localhost:8080/license?shortname="name_of_license_to_search"

Directories

Path Synopsis
cmd
laas command
pkg
api

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL