• Stars
    star
    120
  • Rank 295,983 (Top 6 %)
  • Language
    Kotlin
  • Created about 4 years ago
  • Updated about 4 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

Kotlin RESTful API

API Spec

Authentication

All API must use this authentication

Request :

  • Header :
    • X-Api-Key : "your secret api key"

Create Product

Request :

  • Method : POST
  • Endpoint : /api/products
  • Header :
    • Content-Type: application/json
    • Accept: application/json
  • Body :
{
    "id" : "string, unique",
    "name" : "string",
    "price" : "long",
    "quantity" : "integer"
}

Response :

{
    "code" : "number",
    "status" : "string",
    "data" : {
         "id" : "string, unique",
         "name" : "string",
         "price" : "long",
         "quantity" : "integer",
         "createdAt" : "date",
         "updatedAt" : "date"
     }
}

Get Product

Request :

  • Method : GET
  • Endpoint : /api/products/{id_product}
  • Header :
    • Accept: application/json

Response :

{
    "code" : "number",
    "status" : "string",
    "data" : {
         "id" : "string, unique",
         "name" : "string",
         "price" : "long",
         "quantity" : "integer",
         "createdAt" : "date",
         "updatedAt" : "date"
     }
}

Update Product

Request :

  • Method : PUT
  • Endpoint : /api/products/{id_product}
  • Header :
    • Content-Type: application/json
    • Accept: application/json
  • Body :
{
    "name" : "string",
    "price" : "long",
    "quantity" : "integer"
}

Response :

{
    "code" : "number",
    "status" : "string",
    "data" : {
         "id" : "string, unique",
         "name" : "string",
         "price" : "long",
         "quantity" : "integer",
         "createdAt" : "date",
         "updatedAt" : "date"
     }
}

List Product

Request :

  • Method : GET
  • Endpoint : /api/products
  • Header :
    • Accept: application/json
  • Query Param :
    • size : number,
    • page : number

Response :

{
    "code" : "number",
    "status" : "string",
    "data" : [
        {
             "id" : "string, unique",
             "name" : "string",
             "price" : "long",
             "quantity" : "integer",
             "createdAt" : "date",
             "updatedAt" : "date"
        },
        {
             "id" : "string, unique",
             "name" : "string",
             "price" : "long",
             "quantity" : "integer",
             "createdAt" : "date",
             "updatedAt" : "date"
         }
    ]
}

Delete Product

Request :

  • Method : DELETE
  • Endpoint : /api/products/{id_product}
  • Header :
    • Accept: application/json

Response :

{
    "code" : "number",
    "status" : "string"
}

More Repositories

1

qna

Q&A Bareng Programmer Zaman Now, Orang Ganteng dan Intelek
250
star
2

belajar-javascript-dasar

Belajar JavaScript Dasar
HTML
128
star
3

belajar-mongodb

Belajar MongoDB
JavaScript
112
star
4

belajar-docker-dasar

Belajar Docker Dasar
Shell
100
star
5

belajar-golang-dasar

Belajar GoLang Dasar
Go
98
star
6

belajar-golang-restful-api

Belajar Go-Lang RESTful API
Go
84
star
7

programmerzamannow.github.io

Website Programmer Zaman Now
MDX
66
star
8

belajar-mysql-dasar

Belajar MySQL Dasar
64
star
9

belajar-nodejs-restful-api

Belajar NodeJS RESTful API
JavaScript
62
star
10

belajar-php-dasar

Belajar PHP Dasar
PHP
49
star
11

belajar-laravel-dasar

Belajar Laravel Dasar
PHP
48
star
12

php-login-management

PHP Login Management
PHP
47
star
13

belajar-redis

Belajar Redis
43
star
14

belajar-golang-dasar-2023

Belajar Golang Dasar (update 2023)
Go
41
star
15

belajar-javascript-oop

Belajar JavaScript Object Oriented Programming
HTML
41
star
16

belajar-docker-dockerfile

Belajar Docker Dockerfile
Shell
37
star
17

belajar-docker

Go
36
star
18

belajar-typescript-dasar

Belajar TypeScript Dasar
TypeScript
34
star
19

belajar-php-mvc

Belajar PHP MVC
PHP
34
star
20

belajar-nodejs-dasar

JavaScript
33
star
21

belajar-kotlin-dasar

Belajar Kotlin Dasar
Kotlin
33
star
22

belajar-docker-compose

Belajar Docker Compose
Go
32
star
23

belajar-java-dasar

Belajar Java Dasar
Java
31
star
24

belajar-laravel-restful-api

Belajar Laravel RESTful API
PHP
30
star
25

belajar-dart-dasar

Belajar Pemrograman Dart Dasar
Dart
29
star
26

belajar-golang-dependency-injection

Belajar Go-Lang Dependency Injection
Go
29
star
27

belajar-spring-dasar

Belajar Spring Framework & Spring Boot Dasar
Java
28
star
28

belajar-html-dasar

Belajar HTML Dasar
HTML
26
star
29

belajar-php-oop

Belajar PHP Object Oriented Programming
PHP
25
star
30

belajar-android-dasar

Belajar Android Dasar
Kotlin
25
star
31

belajar-spring-restful-api

Belajar Spring RESTful API
Java
25
star
32

laravel-dasar-todolist

Studi Kasus Laravel Dasar - Membuat Web Login dan Todolist Management
PHP
25
star
33

belajar-golang-unit-test

Belajar Go-Lang Unit Test
Go
25
star
34

pemrograman-python-untuk-pemula

Pemrograman Python untuk Pemula
Python
23
star
35

belajar-typescript-restful-api

Belajar TypeScript RESTful API
TypeScript
23
star
36

studi-kasus-database-design-spotify-clone

Studi Kasus Database Design Spotify Clone
22
star
37

belajar-javascript-standard-library

Belajar JavaScript Standard Library
HTML
22
star
38

belajar-javascript-dom

Belajar JavaScript Document Object Model
HTML
22
star
39

belajar-javascript-async

Belajar JavaScript Async
HTML
21
star
40

belajar-java-oop

Belajar Java Object Oriented Programming
Java
21
star
41

belajar-golang-database-migration

Belajar Golang Database Migration
Go
20
star
42

studi-kasus-php-dasar-aplikasi-todolist

Studi Kasus PHP Dasar - Aplikasi TodoList
PHP
19
star
43

belajar-php-unit-test

Belajar PHP Unit Test
PHP
19
star
44

belajar-golang-goroutines

Belajar Go-Lang Goroutine
Go
19
star
45

belajar-git-dasar

Belajar Git Dasra
18
star
46

studi-kasus-php-oop-aplikasi-todolist

Studi Kasus PHP OOP Aplikasi Todolist
PHP
18
star
47

belajar-jenkins-pipeline

Belajar Jenkins Pipeline
Java
17
star
48

belajar-nodejs-expressjs

Belajar NodeJS ExpressJS
JavaScript
17
star
49

belajar-php-database

Belajar PHP Database
PHP
17
star
50

belajar-php-web

Belajar PHP Web
PHP
17
star
51

belajar-openapi

Belajar OpenAPI
16
star
52

belajar-golang-web

Belajar Go-Lang Web
Go
16
star
53

belajar-golang-generics

Belajar Go-Lang Generics
Go
15
star
54

belajar-dart-oop

Belajar Dart Object Oriented Programming
Dart
15
star
55

belajar-laravel-database

Belajar Laravel Database
PHP
15
star
56

belajar-nestjs-dasar

Belajar NestJS Dasar
TypeScript
15
star
57

belajar-kotlin-oop

Belajar Kotlin Object Oriented Programming
Kotlin
14
star
58

studi-kasus-php-mysql-aplikasi-todolist

Studi Kasus PHP MySQL : Aplikasi Todolist
PHP
14
star
59

belajar-dart-collection

Belajar Dart Collection
Dart
14
star
60

belajar-typescript-oop

Belajar TypeScript Object Oriented Programming
TypeScript
13
star
61

belajar-mysql-notification

Database Design : Notification
13
star
62

belajar-nodejs-todolist-restful-api

JavaScript
13
star
63

belajar-postgresql-dasar

Belajar PostgreSQL Dasar
12
star
64

belajar-golang-datatabase-mysql

Belajar Go-Lang Database MySQL
Go
12
star
65

belajar-javascript-todolist

Belajar JavaScript : Membuat Aplikasi Todolist
HTML
12
star
66

belajar-javascript-modules

Belajar JavaScript Modules
HTML
12
star
67

belajar-laravel-blade-template

Belajar Laravel Blade Template
PHP
11
star
68

belajar-elasticsearch-dasar

Belajar Elasticsearch Dasar
11
star
69

belajar-kotlin-coroutine

Belajar Kotlin Coroutine
Kotlin
11
star
70

belajar-nodejs-database

Belajar NodeJS Databae + Prisma
JavaScript
10
star
71

belajar-nodejs-logging

Belajar NodeJS Logging
JavaScript
10
star
72

belajar-nodejs-unit-test

Belajar NodeJS Unit Test
JavaScript
10
star
73

belajar-laravel-collection

Belajar Laravel Collection
PHP
10
star
74

belajar-laravel-validation

Belajar Laravel Validation
PHP
10
star
75

belajar-vite

Belajar Vite
HTML
10
star
76

belajar-mysql-multi-bahasa

Belajar MySQL Database Design Multi Bahasa
10
star
77

system-design-diagram

System Design Diagram
9
star
78

belajar-golang-json

Belajar Go-Lang JSON
Go
9
star
79

belajar-kotlin-unit-test

Belajar Kotlin Unit Test
Kotlin
9
star
80

php-jwt-session-management

Belajar PHP JWT Session Management
PHP
9
star
81

belajar-kotlin-generic

Belajar Kotlin Generic
Kotlin
9
star
82

belajar-dart-generic

Belajar Dart Generic
Dart
9
star
83

belajar-golang-httprouter

Belajar Go-Lang HttpRouter
Go
9
star
84

belajar-laravel-eloquent

Belajar Laravel Eloquent
PHP
9
star
85

belajar-laravel-11

Belajar Laravel 11
PHP
9
star
86

belajar-php-8

Belajar PHP 8
PHP
8
star
87

belajar-laravel-web-todolist

Belajar Laravel Web Todolist
PHP
8
star
88

belajar-php-81

PHP
8
star
89

belajar-kotlin-collection

Belajar Kotlin Collection
Kotlin
8
star
90

belajar-laravel-logging

Belajar Laravel Logging
PHP
8
star
91

belajar-git-remote

Belajar Git Remote
HTML
8
star
92

belajar-laravel-security

Belajar Laravel Security
PHP
8
star
93

belajar-java-resilience4j

Belajar Java Resilience4J
Java
7
star
94

database-design-tokopedia-order-history

Database Design : Tokopedia Order History
7
star
95

belajar-dart-async

Belajar Dart Async
Dart
7
star
96

belajar-golang-embed

Belajar Go-Lang Embed
Go
7
star
97

belajar-laravel-eloquent-api-resource

Belajar Laravel Eloquent API Resource
PHP
7
star
98

belajar-golang-context

Belajar Go-Lang Context
Go
7
star
99

belajar-typescript-generic

Belajar TypeScript Generic
TypeScript
7
star
100

belajar-golang-kafka-consumer

Belajar Golang Kafka Consumer
Go
7
star