- A vtiger image for send api request
- A memcache server is needed (https://github.com/gizur/beservices)
- A Postfix server is needed to send Email (https://github.com/gizur/beservices)
- Amazon S3 Bucket is needed to save images (Using Aws api)
-
Clone this repo into a LAMP container. See the README of the LAMP container for instructions.
-
Setup the environment using
env.list
in supervisor (/etc/supervisor/conf.d/supervisord.conf
). Don't forget to do:supervisorctl update
. Check http://[IP]:[PORT]/info.php for the environment variables. -
Run
./setup.sh
- Change memcache server detail
- Change vTiger api path
- Change Postfix Server Configuration
see test
0. Prepare credentials:
username=<portal username>
password=<portal password>
url=<API URL http://localhost/api etc.>
1. Login Request
curl -X POST $url/Authenticate/login \
-H "Content-Type:application/json" -H "X-USERNAME:$username" \
-H "X-PASSWORD:$password" -H "X-CLIENTID:clab" -H "ACCEPT-LANGUAGE:en" -H "ACCEPT:json"
2. Assets List Request
curl -X GET $url/Assets \
-H "Content-Type:application/json" -H "X-USERNAME:$username" \
-H "X-PASSWORD:$password" -H "X-CLIENTID:clab" -H "ACCEPT-LANGUAGE:en" -H "ACCEPT:json"
3. For trailer app portal: to get all damages we not use custom and vtiger api, For same we use direct mysql connection.
4. For Assets tab
curl -X GET $url/Assets/Search/s?searchString='' \
-H "Content-Type:application/json" -H "X-USERNAME:$username" \
-H "X-PASSWORD:$password" -H "X-CLIENTID:clab" -H "ACCEPT-LANGUAGE:en" -H "ACCEPT:json"
5. Get All Account
curl -X GET $url/Accounts \
-H "Content-Type:application/json" -H "X-USERNAME:$username" \
-H "X-PASSWORD:$password" -H "X-CLIENTID:clab" -H "ACCEPT-LANGUAGE:en" -H "ACCEPT:json"
6. Get All Products
curl -X GET $url/Products \
-H "Content-Type:application/json" -H "X-USERNAME:$username" \
-H "X-PASSWORD:$password" -H "X-CLIENTID:clab" -H "ACCEPT-LANGUAGE:en" -H "ACCEPT:json"
7. Get Pick list
curl -X GET $url/Assets/trailertype \
-H "Content-Type:application/json" -H "X-USERNAME:$username" \
-H "X-PASSWORD:$password" -H "X-CLIENTID:clab" -H "ACCEPT-LANGUAGE:en" -H "ACCEPT:json"
8. Get All Products
curl -X GET $url/Assets/trailertype \
-H "Content-Type:application/json" -H "X-USERNAME:$username" \
-H "X-PASSWORD:$password" -H "X-CLIENTID:clab" -H "ACCEPT-LANGUAGE:en" -H "ACCEPT:json"
9. Create new Assets
curl -X POST $url/Assets \
-H "Content-Type:application/json" -H "X-USERNAME:$username" \
-H "X-PASSWORD:$password" -H "X-CLIENTID:clab" -H "ACCEPT-LANGUAGE:en" -H "ACCEPT:json" \
-D data