Libraries tagged by to-do

hosam/product-crud

2 Favers
20 Downloads

This package used to do product crud

Go to Download


hopeter1018/developer-tool

1 Favers
48 Downloads

A set of tools to do developer tasks for myself

Go to Download


gish94/yii2-firebase-notifications

1 Favers
33 Downloads

This extension will make send firebase notifications easy to do for the Yii2 framework

Go to Download


ggds/yt-player

0 Favers
0 Downloads

A simple package to do "anon-youtube" player

Go to Download


gerinsp/firepush

1 Favers
1 Downloads

package to do push notifications to FCM(Firebase Cloud Messaging)

Go to Download


geeks4change/composer-pin

0 Favers
1545 Downloads

Provides helper commands to do project level version/hash pinning.

Go to Download


freekattema/wp-zigzagify

0 Favers
0 Downloads

A wordpress plugin to easily change things i have to do with every wordpress project.

Go to Download


fawkescreatives/myanmar-phone

3 Favers
232 Downloads

This package is for building easy to do Myanmar phone number in laravel.

Go to Download


falkemedia/pdf-extractor

1 Favers
14 Downloads

This package automates the generation of an SQLite database that you can use to do a full-text search on a PDF.

Go to Download


exc/todo

0 Favers
13 Downloads

Test task #1: To-Do

Go to Download


enston/laravel-storage-wrapper

0 Favers
28 Downloads

A wrapper for laravel storage using interface. A small package meant to solve having to do all the for cloud storage setup work in each of the projects

Go to Download


ecojuntak/blade-http

0 Favers
9 Downloads

Experimental project to enable Laravel Blade to do HTTP call

Go to Download


easeappphp/json-decode

0 Favers
62 Downloads

This is to do json_decode operation only on valid json string and in a highly performing way.

Go to Download


dgafka/authorization-security

2 Favers
16 Downloads

Take care of authorization concerns for you. Takes out security out of your domain logic and provides clean and easy API to do it.

Go to Download


daphascomp/daphascompsms

0 Favers
1 Downloads

# Authentication Requests made to our APIs must be authenticated, there are two ways to do this: 1. Authenticating using your API apiUsername and apiPassword - `Basic Auth` 2. Authenticating using an Auth Token - `Bearer Token` ## Method 1: Basic Auth Basic Authentication is a method for an HTTP user agent (e.g., a web browser) to provide a apiUsername and apiPassword when making a request. When employing Basic Authentication, users include an encoded string in the Authorization header of each request they make. The string is used by the request’s recipient to verify users’ identity and rights to access a resource. The Authorization header follows this format: > Authorization: Basic base64(apiUsername:apiPassword) So if your apiUsername and apiPassword are `onfon` and `!@pas123`, the combination is `onfon:!@pas123`, and when base64 encoded, this becomes `b25mb246IUBwYXMxMjM=`. So requests made by this user would be sent with the following header: > Authorization: Basic b25mb246IUBwYXMxMjM= | Description | | ---------------------------------------------------------------------------------------------- | | **apiUsername** `String` `Required` Your onfon account apiUsername, retrieved from portal | | **apiPassword** `String` `Required` Your onfon account apiPassword, retrieved from portal | ## Method 2: Bearer Tokens This authentication stategy allows you to authenticate using JSON Web Token ``JWT` that will expire after given duration. Each Access Token is a `JWT`, an encoded JSON object with three parts: the `header`, the `payload`, and the `signature`. The following is an example Access Token generated for Conversations > Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiaWF0IjoxNTE2MjM5MDIyfQ.SflKxwRJSMeKKF2QT4fwpMeJf36POk6yJV_adQssw5c ### Getting the token To generate the token, make a `POST` request to `/v1/authorization` endpoint with your `apiUsername` and `apiPassword` This request should be made from your server and not on the client side such as browser or mobile environment. You will receive a JSON similar to below: `{ "token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiaWF0IjoxNTE2MjM5MDIyfQ.SflKxwRJSMeKKF2QT4fwpMeJf36POk6yJV_adQssw5c", "validDurationSeconds": 3600}` You can use the token received to make API calls. The token will be valid for value of `validDurationSeconds`, before which you should generate a new token. #### Request Body ``` { "apiUsername": "root", "apiPassword": "hakty11" } ``` #### Response Body ``` { "token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiaWF0IjoxNTE2MjM5MDIyfQ.SflKxwRJSMeKKF2QT4fwpMeJf36POk6yJV_adQssw5c", "validDurationSeconds": 3600 } ``` #### Example Curl ``` curl --location --request POST 'https://apis.onfonmedia.co.ke/v1/authorization' \ --data-raw '{ "apiUsername": "correctapiUsername", "apiPassword": "correctapiPassword" } ``` #### Making an API call You will be required to pass the token in `Authorization` header prefixed by `Bearer` when calling other endpoints. Example `Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiaWF0IjoxNTE2MjM5MDIyfQ.SflKxwRJSMeKKF2QT4fwpMeJf36POk6yJV_adQssw5c`

Go to Download


<< Previous Next >>