Skip to content

Instantly share code, notes, and snippets.

View AsaadAbdo's full-sized avatar

Asaad Abdo AsaadAbdo

  • Sun & Sand Sports
  • Dubai, United Arab Emirates
View GitHub Profile
@AsaadAbdo
AsaadAbdo / supervisord.sh
Created January 17, 2018 18:18 — forked from mattupstate/supervisord.sh
Super simple supervisor init.d script
# Supervisord auto-start
#
# description: Auto-starts supervisord
# processname: supervisord
# pidfile: /var/run/supervisord.pid
PATH=/sbin:/usr/sbin:/bin:/usr/bin
NAME=supervisord
DESC="supervisod is a system for controlling process state"
SUPERVISORD=/usr/local/bin/supervisord
<?php
/**
* Author: Asaad Abdo
* Date: 24/5/16
* Time: 3:11 PM
*/
// The below is a sample request to get report using shell
// curl -X POST --data 'args={"username":"dummyksa","password":"dummyksa","data":"16101981015658","method":"get_status"}' http://menavip.com/api/getreport/
<?php
/**
* Author: Asaad Abdo
* Date: 24/5/16
* Time: 3:11 PM
*/
// The below is a sample request to get report using shell
// curl -X POST --data '{"username":"dummyksa", "password":"dummyksa","order_id":"66323", "method":"getOrderReport"}' http://menavip.com/api/getreport/
<?php
/**
* Author: Asaad Abdo
* Date: 24/5/16
* Time: 3:11 PM
*/
// The below is a sample request to create orders using shell
@AsaadAbdo
AsaadAbdo / get-status.sh
Last active September 29, 2015 10:42
Get Order Status Shell cURL sample
# Author : Asaad Abdo
# Date : 29-07-2015
curl -X POST --data 'args={"data":"1512111177997", "method":"get_status", "username":"dummy", "password":"123456789"}' http://menavip.com/client/api/
# Response Sample
# {"status":"Order Created"}
@AsaadAbdo
AsaadAbdo / delivery-api.sh
Last active May 9, 2016 13:23
Delivery shell request sample with response
# Author : Asaad Abdo
# Date : 29-07-2015
# One Shipment
curl -X POST --data 'args={"username":"dummy", "password":"dummy@123","method":"create_orders", "pickup_location":"Dubai", "data":[{"order_reference":"Order_REF", "name":"First Customer", "email":"pratik_goel@live.com", "phone_number":"+987654321", "address":"3201 Golden tower, JLT", "city":"Dubai", "payment_type":"COD","amount":"122", "description":"Samsung mobile - S5 4g", "comments":"Dont call the customer after 400 Pm to schedule"}]}' http://menavip.com/client/api
# Multiple Shipments in one order
curl -X POST --data 'args={"username":"dummy", "password":"dummy@123","method":"create_orders", "pickup_location":"Dubai", "data":[{"order_reference":"Order_REF", "name":"First Customer", "email":"pratik_goel@live.com", "phone_number":"+987654321", "address":"3201 Golden tower, JLT", "city":"Dubai", "payment_type":"COD","amount":"122", "description":"Samsung mobile - S5 4g", "comments":"Dont call the customer after 400 Pm to schedule"},{"order_reference"
<?php
/**
* Created by PhpStorm.
* User: asaadabdo
* Date: 7/16/15
* Time: 5:12 PM
*/
$itemlist[] = array(
'client_ref' => 1000001,
<?php
/**
* Created by PhpStorm.
* User: Asaad Abdo
* Date: 7/8/15
* Time: 8:11 PM
*/
$data = array(
'username' => 'dummy',