browser-sync start --proxy "127.0.0.1:8000" --files "resources/views/**/*.php, public/css/**/*.css, public/js/**/*.js"

php artisan optimize:clear

php artisan cache:clear
php artisan route:clear
php artisan config:clear
php artisan view:clear

/* Mobile Phones (less than 425px) */
@media only screen and (max-width: 425px) {}

/* Tablets (480px to 768px) */
@media only screen and (min-width: 480px) and (max-width: 768px) {}

/* Desktops (768px to 1024px) */
@media only screen and (min-width: 768px) and (max-width: 1024px) {}

/* Large Screens (more than 1024px) */
@media only screen and (min-width: 1024px) {}





 Chapter 3 Protocol Summary

The APIs in this document use AK/SK digest authentication, the AK/SK is generated by the gateway.

- Signature String
 The signature string before calculating consists of HTTP method, headers, and URI, which is defined
 as below.

HTTP METHOD  "\n" 
Accept  "\n" 
Content-MD5  "\n" 
Content-Type "\n" 
Date "\n" 
Headers 
Uri

- HTTP METHOD
 The HTTP method must be upper-case, e.g., "POST".

- Accept
 Setting Accept header is suggested. As for some HTTP clients, if Accept is not configured, the
 default value: */* will automatically be assigned to it, which may cause the failure of signature
 verification.

- Content-MD5
 The Content-MD5 is the value of digest calculated by MD5 algorithm in the request body and
 processed by BASE64 algorithm, and the body must be on non-form format. E.g., String content
MD5=Base64.encodeBase64(MD5(bodyStream.getbytes("UTF-8"))).

- Content-Type
 Content format, such as "text/plain", "text/xml", and "text/json".

 - Date
 Signature date and time.

- Headers
The headers consists of X-Ca-Key, X-Ca-Signature, X-Ca-Signature-Headers, X-Ca-Timestamp, X-Ca
Nonce, and other custom headers. A value will be assigned to each header, the format is
 "header:value\n", in which, the header should be in lower-case and there is no space at front and
 behind of the value, also, it should end with "\n". For headers in a list, they should be sorted
 alphabetically.

- X-Ca-Key
 Required, appKey or appSecret for authentication and it should be obtained by contacting our
 technical supports.
 Make sure the appKey or appSecret is properly kept. Otherwise, please reset it and get a new
 one.
 
- X-Ca-Signature
 Required, signature string.
 
- X-Ca-Signature-Headers
 Required, a lower-case name string of headers that will be calculated in the signature. The
 names in the string will be sorted alphabetically and each two names are separated by
 comma. E.g., x-ca-signature-headers:x-ca-key,x-ca-timestamp.

- Note
 The following headers will not be calculated in the signature: X-Ca-Signature, X-Ca-Signature
Headers, Accept, Content-MD5, Content-Type, Date, Content-Length, Server, Connection, Host,
 Transfer-Encoding, X-Application-Context, and Content-Encoding.

- X-Ca-Timestamp
 Optional, time stamp of calling API, the value equals to the number of milliseconds calculated
 from 00:00:00 on 1st., Jan., 1970 to the current time. E.g., x-ca-timstamp:1550153182830.
 
- X-Ca-Nonce
 Optional, UUID generated when calling API, which is used with the time stamp for anti-replay.

- Uri
 Uniform resource identifier, which consists of resource absolute path and query parameters, e.g.,
 "/artemis/api/example?qa=value1&qb=value2&qc", or "/artemis/api/example".

- Note
 Each header should end with "\n", but if the Accept, Content-MD5, Content-Type, or Date header
 does not exist, "\n" is not required.


The following shows the example of signature string before calculating.

 POST \n
 */* \n
 dGhpcyBpcyBhIGV4YW1wbGU= \n
 text/plain;charset=UTF-8 \n
 Thu, 24 Nov 2016 03:12:25 GMT \n
 a-header:value \n
 b-header:value \n
 x-ca-key:1231243298 \n
 x-ca-timestamp:1479956865000 \n
 /artemis/api/example?a-bodyform=value&a-query=value&b-query=value

- Signature Calculation
1. Calculate the signature string by HmacSHA256 algorithm with the appKey or appSecret to
 generate message digest.
 2. Calculate the message digest by BASE64 algorithm to generate the signature.

- Note
 During the signature calculation, the encoding format is UTF-8.

 The following shows the JAVA sample code of signature calculation:

  Mac hmacSha256 = Mac.getInstance("HmacSHA256");
 byte[] keyBytes = secret.getBytes("UTF-8");
 hmacSha256.init(new SecretKeySpec(keyBytes, 0, keyBytes.length, "HmacSHA256"));
 String sign = new String(Base64.encodeBase64(Sha256.doFinal(stringToSign.getBytes("UTF-8")),"UTF-8"));

- Signature Transfer and Authentication
The signature must be transmitted in the request header, see details in the sample code below.

 /*request URL*/
 http://www.example.com/artemis/api/example?qa=a&qb=B
 /*HTTP method*/
 POST
 /*headers*/
 Accept:*/*
 Accept-Encoding:gzip, deflate, sdch
 Accept-Language:en-US,en;q=0.8
 Connection:keep-alive
 Content-Length:0
 Content-Type:text/plain;charset=UTF-8
 Cookie:JSESSIONID=D9C4A515CACAC31211D1612039D062B7
 header-A:A
 header-B:b
 X-Ca-Key:29666671
 X-Ca-Signature:XeBEg2Ifh+FOfeProHLMYz8luWkJ00Exx7N7tJuats8=
 X-Ca-Signature-Headers:header-a,header-b,x-ca-key,x-ca-timestamp
 X-Ca-Timestamp:1479968678000
 X-Requested-With:XMLHttpRequest
 /*query parameters*/
 qa:a
 qb:B
 /*signature string*/
 POST\n
 */*\n
 text/plain;charset=UTF-8\n
 header-a:A\n
 header-b:b\n
 x-ca-key:29666671\n
 x-ca-timestamp:1479968678000\n
 /artemis/api/example?a-body=a&qa=a&qb=B&x-body=x
 /*signature information*/
 XeBEg2Ifh+FOfeProHLMYz8luWkJ00Exx7N7tJuats8=



















Calling Information
API Name: Get person information
Protocol: HTTP
HTTP Method：POST
Data Type: application/json
Request Path: /api/resource/v1/person/personList
URL:
https://10.10.10.100/artemis/api/resource/v1/person/personList
Security Authentication: AK/SK Authentication

Request Parameter
Header：None
Query：None
Path：None
contentType: application/json
Body：{
    "pageNo": 1,
    "pageSize": 100
}

Authentication Information
Use Simulated Data: No
APPkey：xxxxxxx
APPsecret：xxxxxxxxxxxxxx