From fa2f0bb56ff4f75973526a33b6ef278c8d99bc5a Mon Sep 17 00:00:00 2001 From: weichien00 Date: Tue, 13 Jul 2021 23:07:36 +0800 Subject: [PATCH] update: account registration api - add new input field : business_type. --- resources/views/swagger/json.blade.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/resources/views/swagger/json.blade.php b/resources/views/swagger/json.blade.php index 22d1811a..5a3f7882 100644 --- a/resources/views/swagger/json.blade.php +++ b/resources/views/swagger/json.blade.php @@ -1 +1 @@ -{"swagger":"2.0","info":{"description":"Shipping Portal to manage parcel","version":"1.0.0","title":"Shipping Portal"},"host":"{{request()->getHttpHost()}}","basePath":"/api/v1","tags":[{"name":"Account","description":"Endpoints related to user module, e.g. login, register."},{"name":"Address","description":"Endpoints related to address module, e.g. create, district."},{"name":"Company","description":"Endpoints related to company module."}],"schemes":["http","https"],"paths":{"/address/create":{"post":{"tags":["Address"],"produces":["application/json"],"operationId":"createAddress","summary":"Create address","description":"","parameters":[{"name":"district_id","in":"query","description":"District id","required":true,"type":"integer"},{"name":"street_one","in":"query","description":"Address line 1","required":true,"type":"string"},{"name":"street_two","in":"query","description":"Address line 2","required":true,"type":"string"},{"name":"post_code","in":"query","description":"Postcode of the address","required":true,"type":"string"}],"responses":{"200":{"description":"successful operation","headers":{"X-Expires-After":{"type":"string","format":"date-time","description":"date in UTC when token expires"},"X-Rate-Limit":{"type":"integer","format":"int32","description":"calls per hour allowed by the user"}},"schema":{"type":"string"}},"422":{"description":"Invalid input supplied"}}}},"/address/delete/{id}":{"delete":{"tags":["Address"],"produces":["application/json"],"operationId":"deleteAddress","summary":"Delete address","description":"","parameters":[{"name":"id","in":"path","description":"District id","required":true,"type":"string"}],"responses":{"200":{"description":"successful operation","headers":{"X-Expires-After":{"type":"string","format":"date-time","description":"date in UTC when token expires"},"X-Rate-Limit":{"type":"integer","format":"int32","description":"calls per hour allowed by the user"}},"schema":{"type":"string"}},"422":{"description":"Invalid input supplied"}}}},"/address/district/list":{"get":{"tags":["Address"],"produces":["application/json"],"operationId":"listDistrictAddress","summary":"List districts","description":"","parameters":[{"name":"filter","in":"query","description":"Filters","required":false,"type":"array","items":{"type":"string"}}],"responses":{"200":{"description":"successful operation","headers":{"X-Expires-After":{"type":"string","format":"date-time","description":"date in UTC when token expires"},"X-Rate-Limit":{"type":"integer","format":"int32","description":"calls per hour allowed by the user"}},"schema":{"type":"string"}},"422":{"description":"Invalid input supplied"}}}},"/address/list":{"get":{"tags":["Address"],"produces":["application/json"],"operationId":"listAddress","summary":"List addresses of logged in user","description":"","parameters":[{"name":"filter","in":"query","description":"Filters","required":false,"type":"array","items":{"type":"string"}}],"responses":{"200":{"description":"successful operation","headers":{"X-Expires-After":{"type":"string","format":"date-time","description":"date in UTC when token expires"},"X-Rate-Limit":{"type":"integer","format":"int32","description":"calls per hour allowed by the user"}},"schema":{"type":"string"}},"422":{"description":"Invalid input supplied"}}}},"/address/{id}/show":{"get":{"tags":["Address"],"produces":["application/json"],"operationId":"showAddress","summary":"List addresses of logged in user","description":"","parameters":[{"name":"id","in":"path","description":"Address id","required":true,"type":"integer"}],"responses":{"200":{"description":"successful operation","headers":{"X-Expires-After":{"type":"string","format":"date-time","description":"date in UTC when token expires"},"X-Rate-Limit":{"type":"integer","format":"int32","description":"calls per hour allowed by the user"}},"schema":{"type":"string"}},"422":{"description":"Invalid input supplied"}}}},"/address/{id}/default":{"put":{"tags":["Address"],"produces":["application/json"],"operationId":"setDefaultAddress","summary":"Set default address","description":"","parameters":[{"name":"id","in":"path","description":"Address id","required":true,"type":"integer"},{"name":"district_id","in":"query","description":"District id","required":true,"type":"integer"},{"name":"street_one","in":"query","description":"Address line 1","required":true,"type":"string"},{"name":"street_two","in":"query","description":"Address line 2","required":true,"type":"string"},{"name":"post_code","in":"query","description":"Postcode of the address","required":true,"type":"string"}],"responses":{"200":{"description":"successful operation","headers":{"X-Expires-After":{"type":"string","format":"date-time","description":"date in UTC when token expires"},"X-Rate-Limit":{"type":"integer","format":"int32","description":"calls per hour allowed by the user"}},"schema":{"type":"string"}},"422":{"description":"Invalid input supplied"}}}},"/address/update/{id}":{"put":{"tags":["Address"],"produces":["application/json"],"operationId":"setDefaultAddress","summary":"Set default address","description":"","parameters":[{"name":"id","in":"path","description":"Address id","required":true,"type":"integer"}],"responses":{"200":{"description":"successful operation","headers":{"X-Expires-After":{"type":"string","format":"date-time","description":"date in UTC when token expires"},"X-Rate-Limit":{"type":"integer","format":"int32","description":"calls per hour allowed by the user"}},"schema":{"type":"string"}},"422":{"description":"Invalid input supplied"}}}},"/account/authentication/login/check_email":{"post":{"tags":["Account"],"summary":"Check if email registered","description":"","operationId":"userList","produces":["application/json","application/xml"],"parameters":[{"name":"email","in":"query","description":"email","required":true,"type":"string"}],"responses":{"default":{"description":"successful operation"}}}},"/account/registration/registration":{"post":{"tags":["Account"],"produces":["application/json"],"summary":"Register user into the system","description":"","parameters":[{"name":"name","in":"query","description":"The name of user","required":true,"type":"string"},{"name":"email","in":"query","description":"The email for login","required":true,"type":"string","format":"email"},{"name":"password","in":"query","description":"The password for login","required":true,"type":"string","format":"password"},{"name":"password_confirmation","in":"query","description":"The confirmation password for login","required":true,"type":"string","format":"password"},{"name":"type","in":"query","description":"Account type - 1:Company 2:Individual","required":true,"default":2,"type":"integer"},{"name":"phone","in":"query","description":"Contact phone number","required":true,"type":"string"},{"name":"contact_email","in":"query","description":"Contact email","required":true,"type":"string"},{"name":"company_name","in":"query","description":"The company name - if not defined , name of user will save as the company name","required":false,"type":"string"},{"name":"wechat_id","in":"query","description":"Contact Wechat id","required":false,"type":"string"},{"name":"files[0]","in":"query","description":"File need to convert to base64 example : 'data:application/pdf;base64,{Base64}';","required":true,"type":"string"},{"name":"identification_no","in":"query","description":"Personal identification no or company registration no","required":true,"type":"string"}],"responses":{"200":{"description":"successful operation","headers":{"X-Expires-After":{"type":"string","format":"date-time","description":"date in UTC when token expires"},"X-Rate-Limit":{"type":"integer","format":"int32","description":"calls per hour allowed by the user"}},"schema":{"type":"string"}},"400":{"description":"Invalid username/password supplied"}}}},"/account/authentication/login/attempt":{"post":{"tags":["Account"],"produces":["application/json"],"summary":"Logs user into the system","operationId":"aaa","description":"","parameters":[{"name":"email","in":"query","description":"The user name for login","required":true,"type":"string"},{"name":"password","in":"query","description":"The password for login in clear text","required":true,"type":"string"}],"responses":{"200":{"description":"successful operation","headers":{"X-Expires-After":{"type":"string","format":"date-time","description":"date in UTC when token expires"},"X-Rate-Limit":{"type":"integer","format":"int32","description":"calls per hour allowed by the user"}},"schema":{"type":"string"}},"400":{"description":"Invalid username/password supplied"}}}},"/account/authentication/logout":{"get":{"tags":["Account"],"summary":"Logs out current logged in user session","description":"","operationId":"logoutUser","produces":["application/json","application/xml"],"parameters":[],"responses":{"default":{"description":"successful operation"}}}},"/account/user/list":{"get":{"tags":["Account"],"summary":"Logs out current logged in user session","description":"","operationId":"userList","produces":["application/json","application/xml"],"parameters":[],"responses":{"default":{"description":"successful operation"}}}},"/company/list":{"get":{"tags":["Company"],"summary":"List of Companies","description":"","operationId":"companyList","produces":["application/json","application/xml"],"parameters":[{"name":"filter","in":"query","description":"Filters","required":false,"type":"array","items":{"type":"string"}}],"responses":{"default":{"description":"successful operation"}}}}},"securityDefinitions":{"Authorization":{"type":"apiKey","name":"api_key","in":"header"},"petstore_auth":{"type":"oauth2","authorizationUrl":"https://petstore.swagger.io/oauth/authorize","flow":"implicit","scopes":{"read:pets":"read your pets","write:pets":"modify pets in your account"}}},"definitions":{"ApiResponse":{"type":"object","properties":{"code":{"type":"integer","format":"int32"},"title":{"type":"string"},"message":{"type":"string"},"payload":{"type":"object"}}}}} \ No newline at end of file +{"swagger":"2.0","info":{"description":"Shipping Portal to manage parcel","version":"1.0.0","title":"Shipping Portal"},"host":"{{request()->getHttpHost()}}","basePath":"/api/v1","tags":[{"name":"Account","description":"Endpoints related to user module, e.g. login, register."},{"name":"Address","description":"Endpoints related to address module, e.g. create, district."},{"name":"Company","description":"Endpoints related to company module."}],"schemes":["http","https"],"paths":{"/address/create":{"post":{"tags":["Address"],"produces":["application/json"],"operationId":"createAddress","summary":"Create address","description":"","parameters":[{"name":"district_id","in":"query","description":"District id","required":true,"type":"integer"},{"name":"street_one","in":"query","description":"Address line 1","required":true,"type":"string"},{"name":"street_two","in":"query","description":"Address line 2","required":true,"type":"string"},{"name":"post_code","in":"query","description":"Postcode of the address","required":true,"type":"string"}],"responses":{"200":{"description":"successful operation","headers":{"X-Expires-After":{"type":"string","format":"date-time","description":"date in UTC when token expires"},"X-Rate-Limit":{"type":"integer","format":"int32","description":"calls per hour allowed by the user"}},"schema":{"type":"string"}},"422":{"description":"Invalid input supplied"}}}},"/address/delete/{id}":{"delete":{"tags":["Address"],"produces":["application/json"],"operationId":"deleteAddress","summary":"Delete address","description":"","parameters":[{"name":"id","in":"path","description":"District id","required":true,"type":"string"}],"responses":{"200":{"description":"successful operation","headers":{"X-Expires-After":{"type":"string","format":"date-time","description":"date in UTC when token expires"},"X-Rate-Limit":{"type":"integer","format":"int32","description":"calls per hour allowed by the user"}},"schema":{"type":"string"}},"422":{"description":"Invalid input supplied"}}}},"/address/district/list":{"get":{"tags":["Address"],"produces":["application/json"],"operationId":"listDistrictAddress","summary":"List districts","description":"","parameters":[{"name":"filter","in":"query","description":"Filters","required":false,"type":"array","items":{"type":"string"}}],"responses":{"200":{"description":"successful operation","headers":{"X-Expires-After":{"type":"string","format":"date-time","description":"date in UTC when token expires"},"X-Rate-Limit":{"type":"integer","format":"int32","description":"calls per hour allowed by the user"}},"schema":{"type":"string"}},"422":{"description":"Invalid input supplied"}}}},"/address/list":{"get":{"tags":["Address"],"produces":["application/json"],"operationId":"listAddress","summary":"List addresses of logged in user","description":"","parameters":[{"name":"filter","in":"query","description":"Filters","required":false,"type":"array","items":{"type":"string"}}],"responses":{"200":{"description":"successful operation","headers":{"X-Expires-After":{"type":"string","format":"date-time","description":"date in UTC when token expires"},"X-Rate-Limit":{"type":"integer","format":"int32","description":"calls per hour allowed by the user"}},"schema":{"type":"string"}},"422":{"description":"Invalid input supplied"}}}},"/address/{id}/show":{"get":{"tags":["Address"],"produces":["application/json"],"operationId":"showAddress","summary":"List addresses of logged in user","description":"","parameters":[{"name":"id","in":"path","description":"Address id","required":true,"type":"integer"}],"responses":{"200":{"description":"successful operation","headers":{"X-Expires-After":{"type":"string","format":"date-time","description":"date in UTC when token expires"},"X-Rate-Limit":{"type":"integer","format":"int32","description":"calls per hour allowed by the user"}},"schema":{"type":"string"}},"422":{"description":"Invalid input supplied"}}}},"/address/{id}/default":{"put":{"tags":["Address"],"produces":["application/json"],"operationId":"setDefaultAddress","summary":"Set default address","description":"","parameters":[{"name":"id","in":"path","description":"Address id","required":true,"type":"integer"},{"name":"district_id","in":"query","description":"District id","required":true,"type":"integer"},{"name":"street_one","in":"query","description":"Address line 1","required":true,"type":"string"},{"name":"street_two","in":"query","description":"Address line 2","required":true,"type":"string"},{"name":"post_code","in":"query","description":"Postcode of the address","required":true,"type":"string"}],"responses":{"200":{"description":"successful operation","headers":{"X-Expires-After":{"type":"string","format":"date-time","description":"date in UTC when token expires"},"X-Rate-Limit":{"type":"integer","format":"int32","description":"calls per hour allowed by the user"}},"schema":{"type":"string"}},"422":{"description":"Invalid input supplied"}}}},"/address/update/{id}":{"put":{"tags":["Address"],"produces":["application/json"],"operationId":"setDefaultAddress","summary":"Set default address","description":"","parameters":[{"name":"id","in":"path","description":"Address id","required":true,"type":"integer"}],"responses":{"200":{"description":"successful operation","headers":{"X-Expires-After":{"type":"string","format":"date-time","description":"date in UTC when token expires"},"X-Rate-Limit":{"type":"integer","format":"int32","description":"calls per hour allowed by the user"}},"schema":{"type":"string"}},"422":{"description":"Invalid input supplied"}}}},"/account/authentication/login/check_email":{"post":{"tags":["Account"],"summary":"Check if email registered","description":"","operationId":"userList","produces":["application/json","application/xml"],"parameters":[{"name":"email","in":"query","description":"email","required":true,"type":"string"}],"responses":{"default":{"description":"successful operation"}}}},"/account/registration/registration":{"post":{"tags":["Account"],"produces":["application/json"],"summary":"Register user into the system","description":"","parameters":[{"name":"name","in":"query","description":"The name of user","required":true,"type":"string"},{"name":"email","in":"query","description":"The email for login","required":true,"type":"string","format":"email"},{"name":"password","in":"query","description":"The password for login","required":true,"type":"string","format":"password"},{"name":"password_confirmation","in":"query","description":"The confirmation password for login","required":true,"type":"string","format":"password"},{"name":"type(company type)","in":"query","description":"Company Type - PERSONAL_BUSINESS:0 , COMPANY_BUSINESS:1","required":true,"type":"integer"},{"name":"phone","in":"query","description":"Contact phone number","required":true,"type":"string"},{"name":"contact_email","in":"query","description":"Contact email","required":true,"type":"string"},{"name":"company_name","in":"query","description":"The company name - if not defined , name of user will save as the company name","required":false,"type":"string"},{"name":"type(company_module type)","in":"query","description":"Business Type - FREIGHT_FORWARDER:1, IMPORTER:2, CURRENCY_VENDOR:3, WAREHOUSE:4","required":false,"default":2,"type":"integer"},{"name":"wechat_id","in":"query","description":"Contact Wechat id","required":false,"type":"string"},{"name":"files[0]","in":"query","description":"File need to convert to base64 example : 'data:application/pdf;base64,{Base64}';","required":true,"type":"string"},{"name":"identification_no","in":"query","description":"Personal identification no or company registration no","required":true,"type":"string"}],"responses":{"200":{"description":"successful operation","headers":{"X-Expires-After":{"type":"string","format":"date-time","description":"date in UTC when token expires"},"X-Rate-Limit":{"type":"integer","format":"int32","description":"calls per hour allowed by the user"}},"schema":{"type":"string"}},"400":{"description":"Invalid username/password supplied"}}}},"/account/authentication/login/attempt":{"post":{"tags":["Account"],"produces":["application/json"],"summary":"Logs user into the system","operationId":"aaa","description":"","parameters":[{"name":"email","in":"query","description":"The user name for login","required":true,"type":"string"},{"name":"password","in":"query","description":"The password for login in clear text","required":true,"type":"string"}],"responses":{"200":{"description":"successful operation","headers":{"X-Expires-After":{"type":"string","format":"date-time","description":"date in UTC when token expires"},"X-Rate-Limit":{"type":"integer","format":"int32","description":"calls per hour allowed by the user"}},"schema":{"type":"string"}},"400":{"description":"Invalid username/password supplied"}}}},"/account/authentication/logout":{"get":{"tags":["Account"],"summary":"Logs out current logged in user session","description":"","operationId":"logoutUser","produces":["application/json","application/xml"],"parameters":[],"responses":{"default":{"description":"successful operation"}}}},"/account/user/list":{"get":{"tags":["Account"],"summary":"Logs out current logged in user session","description":"","operationId":"userList","produces":["application/json","application/xml"],"parameters":[],"responses":{"default":{"description":"successful operation"}}}},"/company/list":{"get":{"tags":["Company"],"summary":"List of Companies","description":"","operationId":"companyList","produces":["application/json","application/xml"],"parameters":[{"name":"filter","in":"query","description":"Filters","required":false,"type":"array","items":{"type":"string"}}],"responses":{"default":{"description":"successful operation"}}}}},"securityDefinitions":{"Authorization":{"type":"apiKey","name":"api_key","in":"header"},"petstore_auth":{"type":"oauth2","authorizationUrl":"https://petstore.swagger.io/oauth/authorize","flow":"implicit","scopes":{"read:pets":"read your pets","write:pets":"modify pets in your account"}}},"definitions":{"ApiResponse":{"type":"object","properties":{"code":{"type":"integer","format":"int32"},"title":{"type":"string"},"message":{"type":"string"},"payload":{"type":"object"}}}}} \ No newline at end of file