需要 read_metafileds 权限点。
更多权限点使用信息,请参考:
GET https://{handle}.myshopline.com/admin/openapi/v20250601/metafields.json
handle :店铺的唯一标识符,值为店铺域名的前缀。例如,域名为 open001.myshopline.com 的店铺,其 handleopen001
metafield的店铺资源分页查询
查询参数
  • created_at_max string
    显示在日期之前创建的元字段
    Example: 2021-04-25T16:16:47-04:00
  • created_at_min string
    显示在日期之后创建的元字段
    Example: 2021-04-25T16:15:47-04:00
  • fields string
    要包含在响应中的以逗号分隔的字段列表
    Example: id,key,value
  • key string
    key
    Example: key_123
  • limit integer
    查询数量限制,默认50,不能超过1000
    Example: 10
  • namespace string
    命名空间
    Example: namespace_123
  • page_info string
    分页信息
    Example: ew243redg234dsfr23tdd
  • since_id long
    将结果限制在指定 ID 之后
    Example: 1
  • type string
    value的类型
    Example: single_line_text_field
  • updated_at_max string
    显示在日期之前更新的元字段
    Example: 2021-04-25T16:16:47-04:00
  • updated_at_min string
    显示在日期之后更新的元字段
    Example: 2021-04-25T16:15:47-04:00
请求头
  • Content-Type required
    字段值固定为application/json; charset=utf-8
  • Authorization string required
    资源的访问令牌。请参考 应用授权 获取访问令牌,然后将获取到的访问令牌以 Bearer 格式传入
    Example:
    Bearer eyJhbGciOiJIUzUxMiJ9.eyJhcHBLZXkiOiJmMjM3OWQyMTYyOGMzM2QxMWRiMWZkYjY5N2EzZjdjMjZlNGMwYTA5Iiwic2VsbGVySWQiOiIyMDAwMjM0ODgwIiwic3RvcmVJZCI6IjE2NzIzNjk3Mjk2MDYiLCJ2ZXJzaW9uIjoiVjIiLCJkb21haW4iOiJodHRwczovL3NsLW9wZW4tc2cubXlzaG9wbGluZS5jb20iLCJ0aW1lc3RhbXAiOjE2NzUzMTk0OTI0MzksImlzcyI6Inlzb3VsIiwiZXhwIjoxNzY5OTI3NDkyfQ.UwQzomM2veGCUaOZ0paUxq5dpc7DXuhHYFvsQ_uIAKduzWcb_j2E4q_36El83sp145D4cKbpcE5KCeeIz-JNQw
响应
更多状态码信息请参考 HTTP 状态码

响应头
  • link
    link
  • traceId
    traceId
响应体
  • metafieldsobject[]
    metafield
  • created_at string
    创建时间
    Example: 2022-08-12T12:12:12+00:00
  • description string
    描述
    Example: 我的
  • id long
    metafield的id
    Example: 397424508691
  • key string
    key
    Example: key_123
  • namespace string
    命名空间
    Example: shopline
  • owner_id string
    资源id
    Example: 1656987608691
  • owner_resource string
    资源
    Example: shop
  • type string
    类型
    Example: single_line_text_field
  • updated_at string
    更新时间
    Example: 2022-08-12T12:12:12+00:00
  • value object
    value
    Example: [object Object]
API Explorer
https://openapiceshidianpu.myshopline.com/admin/openapi/v20250601

ParamOptions

header required
query
query
query
query
query
query
query
query
query
query
query

Language

curl --request GET \
--url https://openapiceshidianpu.myshopline.com/admin/openapi/v20250601/metafields.json \
--header 'Authorization: Bearer eyJhbGciOiJIUzUxMiJ9.eyJhcHBLZXkiOiJmMjM3OWQyMTYyOGMzM2QxMWRiMWZkYjY5N2EzZjdjMjZlNGMwYTA5Iiwic2VsbGVySWQiOiIyMDAwMjM0ODgwIiwic3RvcmVJZCI6IjE2NzIzNjk3Mjk2MDYiLCJ2ZXJzaW9uIjoiVjIiLCJkb21haW4iOiJodHRwczovL3NsLW9wZW4tc2cubXlzaG9wbGluZS5jb20iLCJ0aW1lc3RhbXAiOjE2NzUzMTk0OTI0MzksImlzcyI6Inlzb3VsIiwiZXhwIjoxNzY5OTI3NDkyfQ.UwQzomM2veGCUaOZ0paUxq5dpc7DXuhHYFvsQ_uIAKduzWcb_j2E4q_36El83sp145D4cKbpcE5KCeeIz-JNQw' \
--header 'Content-Type: application/json; charset=utf-8' \
--header 'accept: application/json'
Examples
分页查询
Response
{
"metafields": [
{
"created_at": "2022-07-28T07:21:39+00:00",
"description": "omnisend 数据上报id",
"id": 232182358691,
"key": "Omnisned_snippet",
"namespace": "Omnisned_Code",
"owner_id": "1656987608691",
"owner_resource": "shop",
"type": "single_line_text_field",
"updated_at": "2022-07-28T07:21:49+00:00",
"value": "62e238c246ae0adf7c70f96b"
},
{
"created_at": "2022-08-03T08:44:17+00:00",
"id": 236568508691,
"key": "enable",
"namespace": "b2b",
"owner_id": "1656987608691",
"owner_resource": "shop",
"type": "boolean",
"updated_at": "2022-08-03T08:44:17+00:00",
"value": true
},
{
"created_at": "2022-08-03T08:44:17+00:00",
"id": 236568518691,
"key": "inquiry_config",
"namespace": "b2b",
"owner_id": "1656987608691",
"owner_resource": "shop",
"type": "single_line_text_field",
"updated_at": "2022-08-03T08:44:28+00:00",
"value": "{\"hideBuy\":true,\"hidePrice\":true,\"openQuote\":false,\"suspendedEnable\":true,\"suspendedPage\":[\"Home\",\"ProductsDetail\",\"Products\",\"Page\"]}"
},
{
"created_at": "2022-08-03T08:44:17+00:00",
"id": 236590778691,
"key": "inquiry_form_list",
"namespace": "b2b",
"owner_id": "1656987608691",
"owner_resource": "shop",
"type": "single_line_text_field",
"updated_at": "2022-08-03T08:44:28+00:00",
"value": "[{\"id\":\"5522860666308532608\",\"title\":\"Contact us\",\"formName\":\"Default Form\",\"submitContent\":\"Submit\",\"content\":[{\"txt\":\"Name\",\"required\":true,\"textLimit\":255,\"id\":\"5522860666308532609\",\"type\":\"singleLine\",\"placeholder\":{\"txt\":\"Text here...\",\"required\":true,\"textLimit\":20}},{\"txt\":\"Email\",\"required\":true,\"textLimit\":255,\"id\":\"5522860666308532610\",\"type\":\"email\",\"placeholder\":{\"txt\":\"Text here...\",\"required\":true,\"textLimit\":20}},{\"txt\":\"Message\",\"required\":false,\"textLimit\":1024,\"id\":\"5522860666308532611\",\"type\":\"multiline\",\"placeholder\":{\"txt\":\"Text here...\",\"required\":true,\"textLimit\":20}},{\"txt\":\"Files\",\"required\":false,\"textLimit\":5120,\"id\":\"5522860666308532612\",\"type\":\"upload\",\"ext\":\"{\\\"fileNameLengthLimit\\\":255,\\\"suffix\\\":[\\\"pdf\\\",\\\"jpeg\\\",\\\"jpg\\\",\\\"png\\\",\\\"gif\\\"]}\"}],\"createTime\":1659516257206}]"
},
{
"created_at": "2022-08-03T08:44:17+00:00",
"id": 236590788691,
"key": "customer_form_components",
"namespace": "b2b",
"owner_id": "1656987608691",
"owner_resource": "shop",
"type": "single_line_text_field",
"updated_at": "2022-08-03T08:44:40+00:00",
"value": "{\"title\":\"Wholesale Registration\",\"submitContent\":\"Submit\",\"content\":[{\"id\":\"5522860667667487110\",\"type\":\"subtitle\",\"textContent\":\"Customer Information\"},{\"required\":true,\"textLimit\":255,\"id\":\"5522860667667487111\",\"type\":\"name\"},{\"required\":true,\"textLimit\":255,\"id\":\"5522860667684264328\",\"type\":\"email\"},{\"txt\":\"Company\",\"required\":false,\"placeholder\":\"Company name\",\"id\":\"5522860667684264329\",\"type\":\"singleLine\"},{\"txt\":\"Tax ID, ABN, or VAT Number\",\"required\":false,\"placeholder\":\"Tax ID, ABN, or VAT Number\",\"id\":\"5522860667684264330\",\"type\":\"singleLine\"},{\"required\":false,\"id\":\"5522860667684264331\",\"type\":\"phoneNumber\"},{\"txt\":\"Website\",\"required\":false,\"placeholder\":\"Website\",\"id\":\"5522860667684264332\",\"type\":\"singleLine\"},{\"txt\":\"Note\",\"required\":false,\"textLimit\":1024,\"placeholder\":\"Tell us a little about yourself so that we can verify your business identity.\",\"id\":\"5522860667684264333\",\"type\":\"multiline\"},{\"id\":\"5522860667684264334\",\"type\":\"subtitle\",\"textContent\":\"Shipping Address\"},{\"required\":false,\"id\":\"5522860667684264335\",\"type\":\"address\"}]}"
},
{
"created_at": "2022-08-03T08:44:17+00:00",
"id": 236594678691,
"key": "inquiry_form_apply",
"namespace": "b2b",
"owner_id": "1656987608691",
"owner_resource": "shop",
"type": "single_line_text_field",
"updated_at": "2022-08-03T08:44:39+00:00",
"value": "{\"ProductsDetail\":{\"id\":\"5522860666308532608\"},\"Suspended\":{\"id\":\"5522860666308532608\"},\"InquiryCar\":{\"id\":\"5522860666308532608\"}}"
},
{
"created_at": "2022-08-03T11:54:24+00:00",
"id": 236734448691,
"key": "5523052043743008876",
"namespace": "b2b_moq_plan",
"owner_id": "1656987608691",
"owner_resource": "shop",
"type": "single_line_text_field",
"updated_at": "2022-08-03T12:01:37+00:00",
"value": "{\"weight\":1,\"moq\":2,\"applyType\":2,\"batchBuy\":true,\"multipleBuy\":true}"
},
{
"created_at": "2022-08-04T06:37:02+00:00",
"id": 237442018691,
"key": "5524182034371322163",
"namespace": "b2b_step_price_plan",
"owner_id": "1656987608691",
"owner_resource": "shop",
"type": "single_line_text_field",
"updated_at": "2022-08-04T06:37:06+00:00",
"value": "{\"type\":2,\"productRelationType\":2,\"weight\":1,\"rules\":[{\"quantity\":1,\"tiered\":2000}]}"
},
{
"created_at": "2022-08-05T07:06:26+00:00",
"description": "google-site-verification",
"id": 237987768691,
"key": "meta_name",
"namespace": "seo_tool",
"owner_id": "1656987608691",
"owner_resource": "shop",
"type": "single_line_text_field",
"updated_at": "2022-08-05T07:06:27+00:00",
"value": ""
},
{
"created_at": "2022-08-05T07:06:27+00:00",
"description": "Whether breadcrumbs are turned on",
"id": 237995758691,
"key": "bread_crumbs",
"namespace": "seo_tool",
"owner_id": "1656987608691",
"owner_resource": "shop",
"type": "single_line_text_field",
"updated_at": "2022-08-05T07:06:27+00:00",
"value": "0"
},
{
"created_at": "2022-08-08T03:03:40+00:00",
"id": 239514908691,
"key": "member_switch_config_list",
"namespace": "member",
"owner_id": "1656987608691",
"owner_resource": "shop",
"type": "json",
"updated_at": "2022-08-08T03:03:54+00:00",
"value": "{\"switchConfigs\":[{\"storeId\":\"1656987608691\",\"type\":1,\"status\":1},{\"storeId\":\"1656987608691\",\"type\":2,\"status\":0},{\"storeId\":\"1656987608691\",\"type\":3,\"status\":1},{\"storeId\":\"1656987608691\",\"type\":4,\"status\":1},{\"storeId\":\"1656987608691\",\"type\":5,\"status\":0},{\"storeId\":\"1656987608691\",\"type\":100,\"status\":1}]}"
},
{
"created_at": "2022-08-08T03:10:36+00:00",
"id": 239565968691,
"key": "member_step_benefit_list",
"namespace": "member",
"owner_id": "1656987608691",
"owner_resource": "shop",
"type": "json",
"updated_at": "2022-08-08T03:12:18+00:00",
"value": "{\"levelList\":[{\"levelCode\":\"MLC5529772421483860051\",\"levelName\":\"1级会员\",\"weight\":\"1\",\"icon\":\"LEVEL_1\",\"benefitName\":\"$1 off coupon\",\"levelPrivilege\":\"[{\\\"privilegeName\\\":\\\"特权1\\\"}]\",\"levelThreshold\":\"Spend $0\"},{\"levelCode\":\"MLC5529772756524865927\",\"levelName\":\"二级会员\",\"weight\":\"2\",\"icon\":\"LEVEL_2\",\"benefitName\":\"\",\"levelThreshold\":\"Spend $100\"}]}"
},
{
"created_at": "2022-10-13T06:57:41+00:00",
"id": 306011468691,
"key": "attachment_enable",
"namespace": "b2b",
"owner_id": "1656987608691",
"owner_resource": "shop",
"type": "boolean",
"updated_at": "2022-10-13T06:57:41+00:00",
"value": true
},
{
"created_at": "2022-12-28T09:29:35+00:00",
"description": "update",
"id": 397424508691,
"key": "key_123",
"namespace": "shopline",
"owner_id": "1656987608691",
"owner_resource": "shop",
"type": "single_line_text_field",
"updated_at": "2022-12-28T09:56:08+00:00",
"value": "update_value"
}
]
}
这篇文章对你有帮助吗?