Skip to content
This repository was archived by the owner on Nov 19, 2024. It is now read-only.

Commit e8db3a7

Browse files
dewimagentokeharper
authored andcommitted
Users.md (#5909)
* Update users.md * Update users.md * Update users.md * Update users.md * Update users.md
1 parent fb1960e commit e8db3a7

File tree

1 file changed

+67
-59
lines changed

1 file changed

+67
-59
lines changed

marketplace/eqp/v1/users.md

Lines changed: 67 additions & 59 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,8 @@ profile. You must create a new profile on the [Developer Portal](https://develop
1111

1212
## Profile
1313

14-
You must use the `mage_id` associated with the client application in your developer account when making request to these endpoints. You can get this ID when obtaining a [session token](auth.html#session-token).
14+
You must use the `mage_id` associated with the client application in your developer account when making
15+
requests to these endpoints. You can get this ID when obtaining a [session token](auth.html#session-token).
1516

1617
```http
1718
GET /rest/v1/users/:mage_id
@@ -21,7 +22,8 @@ PUT /rest/v1/users/:mage_id
2122

2223
### Get profile data
2324

24-
By default, requests for profile data return all fields. You can limit the amount of data that the request returns by using the `style=summary` option.
25+
By default, requests for profile data return all fields.
26+
You can limit the amount of data that the request returns by using the `style=summary` option.
2527

2628
The following example shows the request/response body for retrieving all profile data:
2729

@@ -38,17 +40,17 @@ curl -X GET \
3840
```json
3941
{
4042
"mage_id": "MAG123456789",
41-
"first_name": Chuck,
42-
"last_name": Norris,
43-
"email": [email protected]",
44-
"screen_name": ninjachuck,
43+
"first_name": "Chuck",
44+
"last_name": "Norris",
45+
"email": "[email protected]",
46+
"screen_name": "ninjachuck",
4547
"has_completed_profile": true,
4648
"has_accepted_tos": true,
4749
"profile_image_artifact": {
4850
"file_upload_id": "uuid-001-234567-123.461",
49-
"filename": chuck.png",
51+
"filename": "chuck.png",
5052
"content_type": "image.png",
51-
"url": https://static-mp.magento.com/user/68/f3/68f360d3516f594fc957c4179ed4a7a872911f07/pub/d9/c2/d9c23dd795a5faaab603b6b5965eca8a6d9430f2/chuck.png,
53+
"url": "https://static-mp.magento.com/user/68/f3/68f360d3516f594fc957c4179ed4a7a872911f07/pub/d9/c2/d9c23dd795a5faaab603b6b5965eca8a6d9430f2/chuck.png",
5254
"size": 1234,
5355
"file_hash": "d5db29cd03a2ed055086cef9c31c252b4587ffff",
5456
"malware_status": "pass"
@@ -57,27 +59,27 @@ curl -X GET \
5759
"tos_accepted_version": "1.0",
5860
"tos_accepted_date": "2017-11-16 01:23:45",
5961
"is_company": false,
60-
"vendor_name": chucknorris,
62+
"vendor_name": "chucknorris",
6163
"partner_level": 4,
6264
"locale": "en-US",
6365
"timezone": "UTC",
6466
"payment_type": 1,
65-
"payment_info": {"paypal_email : [email protected]"},
67+
"payment_info": {"paypal_email" : "[email protected]"},
6668
"taxpayer_type": 2,
67-
"tax_review_status": 3;
69+
"tax_review_status": 3,
6870
"tax_withhold_percent": 0.00,
6971
"extension_share_percent": 0.7,
7072
"theme_share_percent": 0.7,
7173
"install_share_percent": 0,
7274
"support_share_percent": 0,
7375

7476
"personal_profile": {
75-
"bio", Sets ants on fire using a magnifying glass. At night.,
77+
"bio": "Sets ants on fire using a magnifying glass. At night.",
7678
"last_logged_in": "2017-09-30 8:09:10",
7779
"created_at": "2016-02-29 14:04:59",
7880
"modified_at": "2017-11-16 01:23:45",
7981
"social_media_info": {
80-
"twitter": @chucknorrismagento,
82+
"twitter": "@chucknorrismagento",
8183
"stackexchange_url": "",
8284
"facebook_url": "",
8385
"linkedin_url": "",
@@ -86,27 +88,27 @@ curl -X GET \
8688
"addresses": [
8789
{
8890
"address_key": 1,
89-
"address_line_1": "123 Lonestar Way,
90-
"state": Texas,
91-
"country": USA,
92-
"postal_code": 77777,
93-
"phone": 555-1234-5678,
91+
"address_line_1": "123 Lonestar Way",
92+
"state": "Texas",
93+
"country": "USA",
94+
"postal_code": "77777",
95+
"phone": "555-1234-5678",
9496
"country_code": "+1",
9597
"is_primary": true
9698
}
9799
]
98100
},
99101

100102
"company_profile": {
101-
"name": Ninja Norris Inc.,
102-
"bio": Ninja Extension Builder.,
103-
"website_url": "https://www.example.com/,
103+
"name": "Ninja Norris Inc.",
104+
"bio": "Ninja Extension Builder.",
105+
"website_url": "https://www.example.com/",
104106
"primary_email": "[email protected]",
105-
"support_email": "[email protected],
107+
"support_email": "[email protected]",
106108
"created_at": "2016-02-29 14:04:59",
107109
"modified_at": "2017-09-30 01:23:45",
108110
"social_media_info": {
109-
"twitter": @chucknorrismagento,
111+
"twitter": "@chucknorrismagento",
110112
"stackexchange_url": "",
111113
"facebook_url": "",
112114
"linkedin_url": "",
@@ -115,11 +117,11 @@ curl -X GET \
115117
"addresses": [
116118
{
117119
"address_key": 1,
118-
"address_line_1": "123 Lonestar Way,
119-
"state": Texas,
120-
"country": USA,
121-
"postal_code": 77777,
122-
"phone": 555-1234-5678,
120+
"address_line_1": "123 Lonestar Way",
121+
"state": "Texas",
122+
"country": "USA",
123+
"postal_code": "77777",
124+
"phone": "555-1234-5678",
123125
"country_code": "+1",
124126
"is_primary": true
125127
}
@@ -143,17 +145,17 @@ curl -X GET \
143145
```json
144146
{
145147
"mage_id": "MAG123456789",
146-
"first_name": Chuck,
147-
"last_name": Norris,
148-
"email": [email protected]",
149-
"screen_name": ninjachuck,
148+
"first_name": "Chuck",
149+
"last_name": "Norris",
150+
"email": "[email protected]",
151+
"screen_name": "ninjachuck",
150152
"has_completed_profile": true,
151153
"has_accepted_tos": true,
152154
"profile_image_artifact": {
153155
"file_upload_id": "uuid-001-234567-123.461",
154-
"filename": chuck.png",
156+
"filename": "chuck.png",
155157
"content_type": "image.png",
156-
"url": https://static-mp.magento.com/user/68/f3/68f360d3516f594fc957c4179ed4a7a872911f07/pub/d9/c2/d9c23dd795a5faaab603b6b5965eca8a6d9430f2/chuck.png,
158+
"url": "https://static-mp.magento.com/user/68/f3/68f360d3516f594fc957c4179ed4a7a872911f07/pub/d9/c2/d9c23dd795a5faaab603b6b5965eca8a6d9430f2/chuck.png",
157159
"size": 1234,
158160
"file_hash": "d5db29cd03a2ed055086cef9c31c252b4587ffff",
159161
"malware_status": "pass"
@@ -169,25 +171,26 @@ The following example shows a request to update the personal profile bio field:
169171

170172
```json
171173
{
172-
action : publish,
173-
personal_profile : {
174-
bio : I can make a fire by rubbing two ice cubes.
174+
"action" : "publish",
175+
"personal_profile" : {
176+
"bio" : "I can make a fire by rubbing two ice cubes."
175177
}
176178
}
177179
```
178180

179181
The `action` field specifies which update operation to perform:
180182

181-
* `publish`—The default if not specified. Publishes the profile to the relevant [Marketplace Store Partners page](https://marketplace.magento.com/partners.html).
182-
* `draft`—The update is saved on the Developer Portal, but not published.
183+
* `publish` — The default if not specified. Publishes the profile to the relevant
184+
[Marketplace Store Partners page](https://marketplace.magento.com/partners.html).
185+
* `draft` — The update is saved on the Developer Portal, but not published.
183186

184187
**Request**
185188

186189
```bash
187190
curl -X PUT \
188191
-H 'Authorization: Bearer baGXoStRuR9VCDFQGZNzgNqbqu5WUwlr.cAxZJ9m22Le7' \
189192
-H 'Content-Type: application/json' \
190-
-d ‘{ “action: publish”, “personal_profile : { bio : I can make a fire by rubbing two ice cubes. } } \
193+
-d '{ 'action: "publish", "personal_profile" : { "bio" : "I can make a fire by rubbing two ice cubes." } }' \
191194
https://developer-api.magento.com/rest/v1/users/MAG123456789
192195
```
193196
@@ -216,8 +219,8 @@ The following table lists available query parameters, all of which are optional:
216219
217220
| Parameter | Type | Required | Description |
218221
|-----------|--------|----------|----------------------------------------|
219-
| type | string | no | Type of keys requested: 'm1' - Magento 1 product keys, 'm2' - Magento 2 composer repo keys, 'all' - Both M1 and M2 keys (default) |
220-
| label | string | no | The url encoded value of the key label; only valid for 'm2' type.|
222+
| type | string | no | Type of keys requested:<br>`m1` &mdash; Magento 1 product keys<br>`m2` &mdash; Magento 2 composer repo keys<br>`all` &mdash; Both M1 and M2 keys (default)
223+
| label | string | no | The url encoded value of the key label; only valid for `m2` type.|
221224
{:.style="table-layout: auto;"}
222225
223226
The following example shows the request/response body for retrieving keys without any query parameters:
@@ -236,7 +239,7 @@ curl -X GET \
236239
{
237240
"m2": [
238241
{
239-
"label": main_key,
242+
"label": "main_key",
240243
"user_key": "d41d8cd98f00b204e9800998ecf8427e",
241244
"password_key": "12cbdcd3332eb8f166f62ee1a9bd33d0",
242245
"is_enabled": true
@@ -251,8 +254,8 @@ curl -X GET \
251254
252255
"m1": [
253256
{
254-
product_name : acme/one-click-checkout-1.0.0,
255-
product_key : https://connect20.magentocommerce.com/e8c258702e443c509b42fc44a49b83b0/acme+one-click-checkout-1.0.0
257+
"product_name" : "acme/one-click-checkout-1.0.0",
258+
"product_key" : "https://connect20.magentocommerce.com/e8c258702e443c509b42fc44a49b83b0/acme+one-click-checkout-1.0.0"
256259
}
257260
]
258261
}
@@ -261,16 +264,19 @@ curl -X GET \
261264
#### Magento 2 keys
262265
263266
* Each Composer key-pair has unique `label` and `is_enabled` flags to indicate whether the key is enabled.
264-
* A Composer key-pair is identified by `user_key` (username) and `password_key` (password) when prompted for Composer credentials.
267+
* A Composer key-pair is identified by `user_key` (username) and
268+
`password_key` (password) when prompted for Composer credentials.
265269
266270
#### Magento 1 keys
267271
268-
* Provides a list of product names and associated product keys, which can be used in the Magento Connect Manager to install extensions.
272+
* Provides a list of product names and associated product keys,
273+
which can be used in the Magento Connect Manager to install extensions.
269274
* You cannot create, update, or delete these keys.
270275
271276
### Create keys
272277
273-
Use this API to create new Magento 2 Composer key-pairs. You must specify a unique label for each key. You can create multiple key-pairs in a single request.
278+
Use this API to create new Magento 2 Composer key-pairs. You must specify a unique label for each key.
279+
You can create multiple key-pairs in a single request.
274280
275281
```http
276282
POST /rest/v1/users/:mage_id/keys
@@ -295,7 +301,7 @@ POST /rest/v1/users/:mage_id/keys
295301
curl -X POST \
296302
-H 'Authorization: Bearer baGXoStRuR9VCDFQGZNzgNqbqu5WUwlr.cAxZJ9m22Le7' \
297303
-H 'Content-Type: application/json' \
298-
-d ‘{ “m2”: [ { label : key_for_alice }, { label : key_for_charlie } ] } \
304+
-d '{ "m2": [ { "label" : "key_for_alice" }, { "label" : "key_for_charlie" } ] }' \
299305
https://developer-api.magento.com/rest/v1/users/MAG123456789/keys
300306
```
301307
@@ -305,20 +311,20 @@ curl -X POST \
305311
{
306312
"m2": [
307313
{
308-
"label": key_for_alice,
314+
"label": "key_for_alice",
309315
"user_key": "5c75f32248bdd335dc8d8d5a3e5cb52e",
310316
"password_key": "44db283cbb5fdf2c25cbc9352c2a75eb",
311317
"is_enabled": true,
312-
code : 200,
313-
message : Success
318+
"code" : 200,
319+
"message" : "Success"
314320
},
315321
{
316-
"label": "key_for_charlie,
322+
"label": "key_for_charlie",
317323
"user_key": "19ba9488ff99a9346bdeb39ad4ab1a26",
318324
"password_key": "82167d38238911d212cc02a96f3f66f9",
319325
"is_enabled": true,
320-
code : 200,
321-
message : Success
326+
"code" : 200,
327+
"message" : "Success"
322328
}
323329
]
324330
}
@@ -330,7 +336,8 @@ curl -X POST \
330336
331337
### Update keys
332338
333-
Use this API to enable or disable a Magento 2 Composer key-pair. You must specify the key-pair in the request using a URL-encoded string.
339+
Use this API to enable or disable a Magento 2 Composer key-pair.
340+
You must specify the key-pair in the request using a URL-encoded string.
334341
335342
```http
336343
PUT /rest/v1/users/:mage_id/keys/:url_encoded_label_of_m2_key
@@ -342,7 +349,7 @@ PUT /rest/v1/users/:mage_id/keys/:url_encoded_label_of_m2_key
342349
curl -X PUT \
343350
-H 'Authorization: Bearer baGXoStRuR9VCDFQGZNzgNqbqu5WUwlr.cAxZJ9m22Le7' \
344351
-H 'Content-Type: application/json' \
345-
-d ‘{ “m2” : [ { is_enabled : true } ] } \
352+
-d '{ "m2" : [ { "is_enabled" : true } ] }' \
346353
https://developer-api.magento.com/rest/v1/users/MAG123456789/keys/key_for_bob
347354
```
348355
@@ -383,7 +390,8 @@ A 204 No Content HTTP response code indicates a successful update.
383390
384391
## Reports
385392
386-
Use this API to retrieve reports owned by a specific user. Reports contain information about extensions sales, payout status, aggregate sales, refund data, and more.
393+
Use this API to retrieve reports owned by a specific user.
394+
Reports contain information about extensions sales, payout status, aggregate sales, refund data, and more.
387395
388396
```http
389397
GET /rest/v1/users/:mage_id/reports/pageviews
@@ -393,4 +401,4 @@ GET /rest/v1/users/:mage_id/reports/refunds
393401
```
394402
395403
{: .bs-callout-info }
396-
The Reports API specification is under design review. More details will be announced in the future..
404+
The Reports API specification is under design review. More details will be announced in the future.

0 commit comments

Comments
 (0)