客戶API / 編輯客戶
客戶API / 編輯客戶
發布日期:2018-10-27
瀏覽次數:860
1.1 說明
路徑 | /☂/www.your_website_domain.com/FeiEditor/api_v1/shop/customers/update |
方法 | POST |
說明 | 根據用戶ID,修改用戶的一些屬性,用戶名不可以修改,但用戶郵箱可以修改。 |
1.2 參數
名稱 | 必須 | 類型 | 描述 |
id | yes | int | 需要修改用戶的ID |
first_name | No | string | 用戶的名字 |
last_name | No | string | 用戶姓氏 |
No | string | 新的用戶郵箱 | |
password | No | string | 密碼,如果不填則隨機生成密碼 |
1.3 返回結果
正確結果 |
返回格式:JSON |
{ "customer": { "id": 1, "created_at": "2018-10-10T18:00:00Z", "email": "[email protected]", "first_name": "Demo", "last_name": "User", "username": "demouser01", "last_order_id": 123, "last_order_date": "2018-10-10T18:00:00Z", "orders_count": 10, "total_spent": "1034.58", "avatar_url": "", "billing_address": { "first_name": "", "last_name": "", "company": "", "address_1": "", "address_2": "", "city": "", "state": "", "postcode": "", "country": "", "email": "", "phone": "" }, "shipping_address": { "first_name": "", "last_name": "", "company": "", "address_1": "", "address_2": "", "city": "", "state": "", "postcode": "", "country": "" } } } |