{"id":4384,"date":"2024-03-28T20:38:53","date_gmt":"2024-03-28T12:38:53","guid":{"rendered":"http:\/\/www.ponybai.com\/?p=4384"},"modified":"2023-12-18T20:42:08","modified_gmt":"2023-12-18T12:42:08","slug":"%e4%bd%bf%e7%94%a8%e6%90%9c%e7%b4%a2%e5%92%8c%e6%9f%a5%e8%af%a2","status":"publish","type":"post","link":"http:\/\/www.ponybai.com\/?p=4384","title":{"rendered":"\u4f7f\u7528\u641c\u7d22\u548c\u67e5\u8be2"},"content":{"rendered":"\n<p class=\"wp-block-paragraph\">\u672c\u8282\u4e2d\u7684\u793a\u4f8b\u4f7f\u7528 REST API \u8d44\u6e90\u6765\u641c\u7d22\u548c\u67e5\u8be2\u8bb0\u5f55 \u4f7f\u7528 Salesforce \u5bf9\u8c61\u641c\u7d22\u8bed\u8a00 \uff08SOSL\uff09 \u548c Salesforce \u5bf9\u8c61\u67e5\u8be2\u8bed\u8a00 \uff08SOQL\uff09\uff0c\u4ee5\u53ca \u5176\u4ed6\u641c\u7d22 API\u3002\u6709\u5173 SOSL \u548c SOQL \u7684\u8be6\u7ec6\u4fe1\u606f\uff0c\u8bf7\u53c2\u9605\u00a0SOQL \u548c SOSL \u53c2\u8003<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">\u3002<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>\u6267\u884c SOQL<\/strong>\u00a0\u67e5\u8be2 \u4f7f\u7528 Query \u8d44\u6e90\u6267\u884c SOQL \u67e5\u8be2\uff0c\u8be5\u67e5\u8be2<br>\u5728\u5355\u4e2a\u54cd\u5e94\u4e2d\u8fd4\u56de\u6240\u6709\u7ed3\u679c\uff0c\u6216\u8005\u5982\u679c\u9700\u8981\uff0c\u8fd4\u56de\u90e8\u5206\u7ed3\u679c\u548c\u7528\u4e8e\u68c0\u7d22\u5176\u4f59\u7ed3\u679c\u7684\u5b9a\u4f4d\u5668\u3002<\/li>\n\n\n\n<li><strong>\u6267\u884c\u5305\u542b\u5df2\u5220\u9664\u9879\u76ee\u7684<\/strong><br>SOQL \u67e5\u8be2 \u4f7f\u7528 QueryAll \u8d44\u6e90\u6267\u884c SOQL \u67e5\u8be2\uff0c\u8be5\u67e5\u8be2\u5305\u542b\u6709\u5173\u56e0\u5408\u5e76\u6216\u5220\u9664\u800c\u5220\u9664\u7684\u8bb0\u5f55\u7684\u4fe1\u606f\u3002\u4f7f\u7528 QueryAll \u800c\u4e0d\u662f Query\uff0c\u56e0\u4e3a Query \u8d44\u6e90\u5c06\u81ea\u52a8\u7b5b\u9009\u51fa\u5df2\u5220\u9664\u7684\u9879\u3002<\/li>\n\n\n\n<li><strong>\u83b7\u53d6\u6709\u5173\u67e5\u8be2\u6027\u80fd\u7684\u53cd\u9988\uff08\u6d4b\u8bd5\u7248\uff09<\/strong><br>\u8981\u83b7\u53d6\u6709\u5173 Salesforce \u5982\u4f55\u6267\u884c\u67e5\u8be2\u3001\u62a5\u8868\u6216\u5217\u8868\u89c6\u56fe\u7684\u53cd\u9988\uff0c\u8bf7\u4f7f\u7528\u00a0Query\u00a0\u8d44\u6e90\u548c\u00a0explain\u00a0\u53c2\u6570\u3002Salesforce \u4f1a\u5206\u6790\u6bcf\u4e2a\u67e5\u8be2\uff0c\u4ee5\u627e\u5230\u83b7\u53d6\u67e5\u8be2\u7ed3\u679c\u7684\u6700\u4f73\u65b9\u6cd5\u3002\u6839\u636e\u67e5\u8be2\u548c\u67e5\u8be2\u7b5b\u9009\u5668\uff0cSalesforce \u4f7f\u7528\u7d22\u5f15\u6216\u5185\u90e8\u4f18\u5316\u3002\u8981\u8fd4\u56de\u6709\u5173 Salesforce \u5982\u4f55\u4f18\u5316\u67e5\u8be2\u7684\u8be6\u7ec6\u4fe1\u606f\uff0c\u800c\u65e0\u9700\u5b9e\u9645\u8fd0\u884c\u67e5\u8be2\uff0c\u8bf7\u4f7f\u7528\u00a0explain\u00a0\u53c2\u6570\u3002\u6839\u636e\u54cd\u5e94\uff0c\u51b3\u5b9a\u662f\u5426\u5fae\u8c03\u67e5\u8be2\u7684\u6027\u80fd\uff0c\u4f8b\u5982\u6dfb\u52a0\u7b5b\u9009\u5668\u4ee5\u4f7f\u67e5\u8be2\u66f4\u5177\u9009\u62e9\u6027\u3002<\/li>\n\n\n\n<li><strong>\u641c\u7d22\u5b57\u7b26\u4e32<\/strong><br>\u4f7f\u7528 Search \u8d44\u6e90\u6267\u884c SOSL \u641c\u7d22\uff0c\u6216\u4f7f\u7528 Parameterized Search \u8d44\u6e90\u6267\u884c\u4e0d\u5e26 SOSL \u7684\u7b80\u5355 RESTful \u641c\u7d22\u3002<\/li>\n\n\n\n<li>\u83b7\u53d6\u9ed8\u8ba4\u641c\u7d22\u8303\u56f4\u548c\u987a\u5e8f \u4f7f\u7528\u201c\u641c\u7d22\u8303\u56f4\u548c\u987a\u5e8f\u201d\u8d44\u6e90\u68c0\u7d22\u767b\u5f55\u7528\u6237\u7684<strong>\u9ed8\u8ba4\u5168\u5c40\u641c\u7d22\u8303\u56f4\u548c\u987a\u5e8f<\/strong><br>\uff0c\u5305\u62ec\u7528\u6237\u641c\u7d22\u7ed3\u679c\u9875\u4e2d\u7684\u4efb\u4f55\u56fa\u5b9a\u5bf9\u8c61\u3002<\/li>\n\n\n\n<li><strong>\u83b7\u53d6<\/strong>\u5bf9\u8c61\u7684\u641c\u7d22\u7ed3\u679c\u5e03\u5c40 \u4f7f\u7528\u201c\u641c\u7d22\u7ed3\u679c\u5e03\u5c40\u201d\u8d44\u6e90\u68c0\u7d22\u67e5\u8be2\u5b57\u7b26\u4e32\u4e2d\u6307\u5b9a\u7684\u6bcf\u4e2a\u5bf9\u8c61<br>\u7684\u641c\u7d22\u7ed3\u679c\u5e03\u5c40\u914d\u7f6e\u3002<\/li>\n\n\n\n<li><strong>\u67e5\u770b<\/strong>\u76f8\u5173\u9879\u76ee \u4f7f\u7528\u201c\u76f8\u5173\u9879\u76ee<br>\u201d\u8d44\u6e90\u83b7\u53d6\u76f8\u5173\u8bb0\u5f55\u7684\u5217\u8868\u3002<\/li>\n<\/ul>\n\n\n\n<h2 class=\"wp-block-heading\">\u6267\u884c SOQL \u67e5\u8be2<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">\u4f7f\u7528\u00a0Query\u00a0\u8d44\u6e90\u6267\u884c SOQL \u67e5\u8be2\uff0c\u8be5\u67e5\u8be2\u5728\u5355\u4e2a\u54cd\u5e94\u4e2d\u8fd4\u56de\u6240\u6709\u7ed3\u679c\uff0c\u6216\u8005 \u5982\u679c\u9700\u8981\uff0c\u8fd4\u56de\u90e8\u5206\u7ed3\u679c\u548c\u7528\u4e8e\u68c0\u7d22\u5269\u4f59\u7ed3\u679c\u7684\u5b9a\u4f4d\u5668 \u7ed3\u679c\u3002<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">\u4ee5\u4e0b\u67e5\u8be2\u8bf7\u6c42\u6240\u6709&nbsp;name&nbsp;\u5b57\u6bb5\u4e2d\u7684\u503c \u5e10\u6237\u8bb0\u5f55\u3002\u6267\u884c\u67e5\u8be2\u7684\u793a\u4f8b\u7528\u6cd5<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>curl https:\/\/<em>MyDomainName<\/em>.my.salesforce.com\/services\/data\/v59.0\/query\/?q=SELECT+name+from+Account -H \"Authorization: Bearer <em>token<\/em>\"<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">\u7528\u4e8e\u6267\u884c\u67e5\u8be2\u7684\u793a\u4f8b\u8bf7\u6c42\u6b63\u6587\u4e0d\u9700\u8981\u7528\u4e8e\u6267\u884c\u67e5\u8be2\u7684\u793a\u4f8b\u54cd\u5e94\u6b63\u6587<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>{\n    \"done\" : true,\n    \"totalSize\" : 14,\n    \"records\" : \n    &#91; \n        {  \n            \"attributes\" : \n            {    \n                \"type\" : \"Account\",    \n                \"url\" : \"\/services\/data\/v59.0\/sobjects\/Account\/001D000000IRFmaIAH\"  \n            },  \n            \"Name\" : \"Test 1\"\n        }, \n        {  \n            \"attributes\" : \n            {    \n                \"type\" : \"Account\",    \n                \"url\" : \"\/services\/data\/v59.0\/sobjects\/Account\/001D000000IomazIAB\"  \n            },  \n            \"Name\" : \"Test 2\"\n        }, \n\n        ...\n\n    ]\n}<\/code><\/pre>\n\n\n\n<h2 class=\"wp-block-heading\"><a><\/a>\u68c0\u7d22\u5269\u4f59\u7684 SOQL \u67e5\u8be2 \u7ed3\u679c<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">\u5982\u679c\u521d\u59cb\u67e5\u8be2\u4ec5\u8fd4\u56de\u90e8\u5206\u7ed3\u679c\uff0c\u5219\u54cd\u5e94\u7ed3\u675f \u5305\u542b\u4e00\u4e2a\u540d\u4e3a \uff1a<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><samp>nextRecordsUrl<\/samp><\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>\"nextRecordsUrl\" : \"\/services\/data\/v59.0\/query\/01gD0000002HU6KIAW-2000\"<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">\u5728\u8fd9\u79cd\u60c5\u51b5\u4e0b\uff0c\u8bf7\u6c42\u4e0b\u4e00\u6279\u8bb0\u5f55\u5e76\u91cd\u590d\uff0c\u76f4\u5230\u6240\u6709\u8bb0\u5f55\u90fd \u88ab\u68c0\u7d22\u5230\u3002\u8fd9\u4e9b\u8bf7\u6c42\u4f7f\u7528 \uff0c\u5e76\u4e14\u4e0d\u5305\u542b\u4efb\u4f55\u53c2\u6570\u3002<samp>nextRecordsUrl<\/samp>\u68c0\u7d22\u5269\u4f59\u67e5\u8be2\u7ed3\u679c\u7684\u793a\u4f8b\u7528\u6cd5<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>curl https:\/\/<em>MyDomainName<\/em>.my.salesforce.com\/services\/data\/v59.0\/query\/01gD0000002HU6KIAW-2000 -H \"Authorization: Bearer <em>token<\/em>\"<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">\u7528\u4e8e\u68c0\u7d22\u5269\u4f59\u67e5\u8be2\u7ed3\u679c\u7684\u793a\u4f8b\u8bf7\u6c42\u6b63\u6587\u4e0d\u9700\u8981\u7528\u4e8e\u68c0\u7d22\u5269\u4f59\u67e5\u8be2\u7ed3\u679c\u7684\u793a\u4f8b\u54cd\u5e94\u6b63\u6587<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>{\n    \"done\" : true,\n    \"totalSize\" : 3214,\n    \"records\" : &#91;...]\n}<\/code><\/pre>\n\n\n\n<h2 class=\"wp-block-heading\">\u6267\u884c\u5305\u542b\u4ee5\u4e0b\u5185\u5bb9\u7684 SOQL \u67e5\u8be2 \u5df2\u5220\u9664\u7684\u9879\u76ee<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">\u4f7f\u7528\u00a0QueryAll\u00a0\u8d44\u6e90\u6267\u884c SOQL \u67e5\u8be2\uff0c\u5176\u4e2d\u5305\u62ec \u6709\u5173\u56e0\u5408\u5e76\u6216\u5220\u9664\u800c\u5220\u9664\u7684\u8bb0\u5f55\u7684\u4fe1\u606f\u3002\u7528 QueryAll \u800c\u4e0d\u662f Query\uff0c\u56e0\u4e3a Query \u8d44\u6e90\u5c06\u81ea\u52a8\u7b5b\u9009\u6389 \u5df2\u5220\u9664\u7684\u9879\u76ee\u3002<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">\u4ee5\u4e0b\u67e5\u8be2\u8bf7\u6c42\u6240\u6709&nbsp;Name&nbsp;\u5b57\u6bb5\u4e2d\u7684\u503c \u5df2\u5220\u9664\u7684Merchandise__c\u8bb0\u5f55\uff0c\u5728\u5177\u6709\u4e00\u4e2a\u5df2\u5220\u9664Merchandise__c\u7684\u7ec4\u7ec7\u4e2d \u8bb0\u5f55\u3002\u4f7f\u7528 Query \u800c\u4e0d\u662f QueryAll \u7684\u540c\u4e00\u67e5\u8be2\u4e0d\u4f1a\u8fd4\u56de\u4efb\u4f55\u8bb0\u5f55\uff0c\u56e0\u4e3a \u67e5\u8be2\u4f1a\u81ea\u52a8\u4ece\u7ed3\u679c\u96c6\u4e2d\u7b5b\u9009\u51fa\u4efb\u4f55\u5df2\u5220\u9664\u7684\u8bb0\u5f55\u3002\u5bf9\u5df2\u5220\u9664\u7684Merchandise__c\u8bb0\u5f55\u6267\u884c\u67e5\u8be2\u7684\u793a\u4f8b\u7528\u6cd5<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>curl https:\/\/<em>MyDomainName<\/em>.my.salesforce.com\/services\/data\/v59.0\/queryAll\/?q=SELECT+Name+from+Merchandise__c+WHERE+isDeleted+=+TRUE -H \"Authorization: Bearer <em>token<\/em>\"<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">\u7528\u4e8e\u6267\u884c\u67e5\u8be2\u7684\u793a\u4f8b\u8bf7\u6c42\u6b63\u6587\u4e0d\u9700\u8981\u7528\u4e8e\u6267\u884c\u67e5\u8be2\u7684\u793a\u4f8b\u54cd\u5e94\u6b63\u6587<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>{\n    \"done\" : true,\n    \"totalSize\" : 1,\n    \"records\" : \n    &#91; \n        {  \n            \"attributes\" : \n            {    \n                \"type\" : \"Merchandise__c\",    \n                \"url\" : \"\/services\/data\/v59.0\/sobjects\/Merchandise__c\/a00D0000008pQRAIX2\"  \n            },  \n            \"Name\" : \"Merchandise 1\"\n        }, \n    ]\n}<\/code><\/pre>\n\n\n\n<h2 class=\"wp-block-heading\"><a><\/a>\u68c0\u7d22\u5269\u4f59\u7684 SOQL \u67e5\u8be2 \u7ed3\u679c<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">\u5982\u679c\u521d\u59cb\u67e5\u8be2\u4ec5\u8fd4\u56de\u90e8\u5206\u7ed3\u679c\uff0c\u5219\u54cd\u5e94\u7684\u672b\u5c3e\u5c06 \u5305\u542b\u4e00\u4e2a\u540d\u4e3a \u7684\u5b57\u6bb5\u3002\u4e3a \u4f8b\u5982\uff0c\u60a8\u53ef\u80fd\u4f1a\u5728 \u67e5\u8be2\uff1a<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><samp>nextRecordsUrl<\/samp><\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>\"nextRecordsUrl\" : \"\/services\/data\/v59.0\/query\/01gD0000002HU6KIAW-2000\"<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">\u5728\u8fd9\u79cd\u60c5\u51b5\u4e0b\uff0c\u8bf7\u6c42\u4e0b\u4e00\u6279\u8bb0\u5f55\u5e76\u91cd\u590d\uff0c\u76f4\u5230\u6240\u6709\u8bb0\u5f55\u90fd \u88ab\u68c0\u7d22\u5230\u3002\u8fd9\u4e9b\u8bf7\u6c42\u4f7f\u7528 \uff0c\u5e76\u4e14\u4e0d\u5305\u542b\u4efb\u4f55\u53c2\u6570\u3002<samp>nextRecordsUrl<\/samp><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">\u867d\u7136\u6709 URL \u65f6\uff0c\u5b83\u4ecd\u4f1a\u63d0\u4f9b\u521d\u59cb QueryAll \u8bf7\u6c42\u7684\u5269\u4f59\u7ed3\u679c\u3002 \u5176\u4f59\u7ed3\u679c\u5305\u62ec\u4e0e\u521d\u59cb\u5339\u914d\u7684\u5df2\u5220\u9664\u8bb0\u5f55 \u67e5\u8be2\u3002<samp>nextRecordsUrl<\/samp><samp>query<\/samp>\u68c0\u7d22\u5269\u4f59\u7ed3\u679c\u7684\u793a\u4f8b\u7528\u6cd5<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>curl https:\/\/<em>MyDomainName<\/em>.my.salesforce.com\/services\/data\/v59.0\/query\/01gD0000002HU6KIAW-2000 -H \"Authorization: Bearer <em>token<\/em>\"<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">\u7528\u4e8e\u68c0\u7d22\u5176\u4f59\u7ed3\u679c\u7684\u793a\u4f8b\u8bf7\u6c42\u6b63\u6587\u4e0d\u9700\u8981\u7528\u4e8e\u68c0\u7d22\u5269\u4f59\u7ed3\u679c\u7684\u793a\u4f8b\u54cd\u5e94\u6b63\u6587<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>{\n    \"done\" : true,\n    \"totalSize\" : 3214,\n    \"records\" : &#91;...]\n}<\/code><\/pre>\n\n\n\n<h2 class=\"wp-block-heading\">\u83b7\u53d6\u6709\u5173\u67e5\u8be2\u6027\u80fd\u7684\u53cd\u9988\uff08\u6d4b\u8bd5\u7248\uff09<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">\u8981\u83b7\u53d6\u6709\u5173 Salesforce \u5982\u4f55\u6267\u884c\u67e5\u8be2\u3001\u62a5\u544a\u6216\u5217\u8868\u89c6\u56fe\u7684\u53cd\u9988\uff0c\u8bf7\u4f7f\u7528\u00a0Query\u00a0\u8d44\u6e90\u4ee5\u53ca\u00a0explain\u00a0\u53c2\u6570\u3002Salesforce \u4f1a\u5206\u6790\u6bcf\u4e2a\u67e5\u8be2\u4ee5\u627e\u5230\u6700\u4f73\u67e5\u8be2 \u65b9\u6cd5\u83b7\u53d6\u67e5\u8be2\u7ed3\u679c\u3002\u6839\u636e\u67e5\u8be2\u548c\u67e5\u8be2\u7b5b\u9009\u5668\uff0cSalesforce \u4f7f\u7528\u7d22\u5f15\u6216\u5185\u90e8\u4f18\u5316\u3002\u8981\u8fd4\u56de\u6709\u5173 Salesforce \u5982\u4f55\u4f18\u5316 query\uff0c\u800c\u4e0d\u5b9e\u9645\u8fd0\u884c\u67e5\u8be2\uff0c\u4f7f\u7528\u00a0explain\u00a0\u53c2\u6570\u3002 \u6839\u636e\u54cd\u5e94\uff0c\u51b3\u5b9a\u662f\u5426\u5fae\u8c03\u67e5\u8be2\u7684\u6027\u80fd\uff0c\u4f8b\u5982\u6dfb\u52a0 \u7b5b\u9009\u5668\uff0c\u4f7f\u67e5\u8be2\u66f4\u5177\u9009\u62e9\u6027\u3002<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">\u6ce8\u610f<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">\u6b64\u529f\u80fd\u662f\u4e00\u9879\u6d4b\u8bd5\u7248\u670d\u52a1\u3002\u5ba2\u6237\u53ef\u4ee5\u9009\u62e9\u5355\u72ec\u8bd5\u7528\u6b64\u7c7b\u6d4b\u8bd5\u7248\u670d\u52a1 \u81ea\u7531\u88c1\u91cf\u6743\u3002\u5bf9\u6d4b\u8bd5\u7248\u670d\u52a1\u7684\u4efb\u4f55\u4f7f\u7528\u5747\u53d7\u9002\u7528\u7684\u6d4b\u8bd5\u7248\u670d\u52a1\u6761\u6b3e\u7684\u7ea6\u675f \u5728\u534f\u8bae\u548c\u6761\u6b3e\u4e2d\u63d0\u4f9b\u3002<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">\u54cd\u5e94\u5305\u542b\u4e00\u4e2a\u6216\u591a\u4e2a\u67e5\u8be2\u6267\u884c\u8ba1\u5212\uff0c\u6309\u4ece\u6700\u4f18\u5230\u6700\u5c11\u7684\u987a\u5e8f\u6392\u5e8f \u6700\u4f73\u7684\u3002\u6700\u4f73\u8ba1\u5212\u662f\u5f53\u67e5\u8be2\u3001\u62a5\u8868\u6216\u5217\u8868\u89c6\u56fe\u4e3a \u6267\u884c\u3002<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">\u6709\u5173\u4f7f\u7528 explain \u65f6\u8fd4\u56de\u7684\u5b57\u6bb5\u7684\u66f4\u591a\u8be6\u7ec6\u4fe1\u606f\uff0c\u8bf7\u53c2\u9605\u67e5\u8be2\u9009\u9879\u6807\u5934\u4e2d\u7684\u00a0explain\u00a0\u53c2\u6570\u3002\u67e5\u770b\u66f4\u591a \u6709\u5173\u4f7f\u67e5\u8be2\u66f4\u5177\u9009\u62e9\u6027\u7684\u4fe1\u606f\uff0c\u8bf7\u53c2\u9605\u4f7f\u7528\u8d85\u5927\u578b SOQL\u00a0\u300aApex \u5f00\u53d1\u4eba\u5458\u6307\u5357\u300b\u4e2d\u7684\u67e5\u8be2\u3002<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">\u793a\u4f8b\uff1a\u5bf9\u67e5\u8be2\u6027\u80fd\u7684\u53cd\u9988<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">\u4ee5\u4e0b\u6027\u80fd\u53cd\u9988\u67e5\u8be2\u4f7f\u7528\uff1a<var>Merchandise__c<\/var><\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>curl https:\/\/<em>MyDomainName<\/em>.my.salesforce.com\/services\/data\/v59.0\/query\/?explain=\nSELECT+Name+FROM+Merchandise__c+WHERE+CreatedDate+=+TODAY+AND+Price__c+&gt;+10.0<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">\u6027\u80fd\u53cd\u9988\u67e5\u8be2\u7684\u54cd\u5e94\u6b63\u6587\u5982\u4e0b\u6240\u793a\uff1a<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>{\n  \"plans\" : &#91; {\n    \"cardinality\" : 1,\n    \"fields\" : &#91; \"CreatedDate\" ],\n    \"leadingOperationType\" : \"Index\",\n    \"notes\" :  &#91; {\n      \"description\" : \"Not considering filter for optimization because unindexed\",\n      \"fields\" : &#91; \"IsDeleted\" ],\n      \"tableEnumOrId\" : \"Merchandise__c\"\n    } ],\n    \"relativeCost\" : 0.0,\n    \"sobjectCardinality\" : 3,\n    \"sobjectType\" : \"Merchandise__c\"\n  }, {\n    \"cardinality\" : 1,\n    \"fields\" : &#91; ],\n    \"leadingOperationType\" : \"TableScan\",\n    \"notes\" :  &#91; {\n      \"description\" : \"Not considering filter for optimization because unindexed\",\n      \"fields\" : &#91; \"IsDeleted\" ],\n      \"tableEnumOrId\" : \"Merchandise__c\"\n    } ],\n    \"relativeCost\" : 0.65,\n    \"sobjectCardinality\" : 3,\n    \"sobjectType\" : \"Merchandise__c\"\n  } ]\n}<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">\u6b64\u54cd\u5e94\u8868\u660e Salesforce \u4e3a\u6b64\u67e5\u8be2\u627e\u5230\u4e86\u4e24\u4e2a\u53ef\u80fd\u7684\u6267\u884c\u8ba1\u5212\u3002 \u7b2c\u4e00\u4e2a\u8ba1\u5212\u4f7f\u7528 CreatedDate \u7d22\u5f15\u5b57\u6bb5\u6765\u63d0\u9ad8\u6b64\u67e5\u8be2\u7684\u6027\u80fd\u3002 \u7b2c\u4e8c\u4e2a\u8ba1\u5212\u5728\u4e0d\u4f7f\u7528\u7d22\u5f15\u7684\u60c5\u51b5\u4e0b\u626b\u63cf\u6240\u6709\u8bb0\u5f55\u3002\u5982\u679c\u6267\u884c\u67e5\u8be2\uff0c\u5219 \u4f7f\u7528\u7b2c\u4e00\u4e2a\u8ba1\u5212\u3002\u8fd9\u4e24\u4e2a\u8ba1\u5212\u90fd\u6307\u51fa\uff0c\u6ca1\u6709\u7528\u4e8e\u8fc7\u6ee4\u7684\u4e8c\u6b21\u4f18\u5316 \u6807\u8bb0\u4e3a\u5df2\u5220\u9664\u7684\u8bb0\u5f55\uff0c\u56e0\u4e3a IsDeleted \u5b57\u6bb5\u672a\u7f16\u5236\u7d22\u5f15\u3002<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">\u641c\u7d22\u5b57\u7b26\u4e32<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\"><a><\/a>\u4f7f\u7528\u641c\u7d22\u8d44\u6e90\u6267\u884c SOSL \u641c\u7d22\u6216\u4f7f\u7528 \u53c2\u6570\u5316\u641c\u7d22\u8d44\u6e90\uff0c\u7528\u4e8e\u6267\u884c\u7b80\u5355\u7684 RESTful \u641c\u7d22\uff0c\u800c\u65e0\u9700 SOSL\u7684\u3002<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">SOSL \u793a\u4f8b \u4f7f\u7528 GET \u65b9\u6cd5\u8fdb\u884c\u641c\u7d22<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">\u4ee5\u4e0b\u793a\u4f8b\u6267\u884c SOSL \u641c\u7d22\u3002\u6b64\u793a\u4f8b\u4e2d\u7684\u641c\u7d22\u5b57\u7b26\u4e32\u5fc5\u987b\u7ecf\u8fc7 URL \u7f16\u7801\u3002<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><samp>Acme<\/samp>\u793a\u4f8b\u7528\u6cd5<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>curl https:\/\/<em>MyDomainName<\/em>.my.salesforce.com\/services\/data\/v59.0\/search\/?q=FIND+%7BAcme%7D -H \"Authorization: Bearer <em>token<\/em>\"<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">\u793a\u4f8b\u8bf7\u6c42\u6b63\u6587\u4e0d\u9700\u8981\u793a\u4f8b\u54cd\u5e94\u6b63\u6587<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>{\n  \"searchRecords\" : &#91; {\n    \"attributes\" : {\n      \"type\" : \"Account\",\n      \"url\" : \"\/services\/data\/v59.0\/sobjects\/Account\/001D000000IqhSLIAZ\"\n    },\n    \"Id\" : \"001D000000IqhSLIAZ\",\n  }, {\n    \"attributes\" : {\n      \"type\" : \"Account\",\n      \"url\" : \"\/services\/data\/v59.0\/sobjects\/Account\/001D000000IomazIAB\"\n    },\n    \"Id\" : \"001D000000IomazIAB\",\n  } ]\n}<\/code><\/pre>\n\n\n\n<h2 class=\"wp-block-heading\">\u4f7f\u7528 GET \u65b9\u6cd5\u7684\u53c2\u6570\u5316\u641c\u7d22\u793a\u4f8b<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">\u4ee5\u4e0b\u793a\u4f8b \u6267\u884c\u5bf9 \u7684\u53c2\u6570\u5316\u641c\u7d22\u3002\u8fd9 \u6b64\u793a\u4f8b\u4e2d\u7684\u641c\u7d22\u5b57\u7b26\u4e32\u5fc5\u987b\u7ecf\u8fc7 URL \u7f16\u7801\u3002<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><samp>Acme<\/samp>\u793a\u4f8b\u7528\u6cd5<strong>\u5bf9\u5305\u542b&nbsp;<em>Acme<\/em>&nbsp;\u7684\u6240\u6709\u7ed3\u679c\u8fdb\u884c\u5168\u5c40\u641c\u7d22<\/strong><\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>curl https:\/\/<em>MyDomainName<\/em>.my.salesforce.com\/services\/data\/v59.0\/parameterizedSearch\/?q=Acme -H \"Authorization: Bearer <em>token<\/em>\"<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>\u5e10\u6237\u641c\u7d22\u5305\u542b&nbsp;<em>Acme<\/em>&nbsp;\u7684\u7ed3\u679c\uff0c\u8fd4\u56de id \u548c \u540d\u79f0\u5b57\u6bb5<\/strong><\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>curl https:\/\/<em>MyDomainName<\/em>.my.salesforce.com\/services\/data\/v59.0\/parameterizedSearch\/?q=Acme&amp;sobject=Account&amp;Account.fields=id,name&amp;Account.limit=10 -H \"Authorization: Bearer <em>token<\/em>\"<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">\u793a\u4f8b\u8bf7\u6c42\u6b63\u6587\u4e0d\u9700\u8981\u793a\u4f8b\u54cd\u5e94\u6b63\u6587<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>{\n  \"searchRecords\" : &#91; {\n    \"attributes\" : {\n      \"type\" : \"Account\",\n      \"url\" : \"\/services\/data\/v59.0\/sobjects\/Account\/001D000000IqhSLIAZ\"\n    },\n    \"Id\" : \"001D000000IqhSLIAZ\"\n  }, {\n    \"attributes\" : {\n      \"type\" : \"Account\",\n      \"url\" : \"\/services\/data\/v59.0\/sobjects\/Account\/001D000000IomazIAB\"\n    },\n    \"Id\" : \"001D000000IomazIAB\"\n  } ]\n}<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">\u5177\u6709\u5143\u6570\u636e\u53c2\u6570\u7684\u793a\u4f8b\u54cd\u5e94\u6b63\u6587<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">\u6ce8\u610f<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">\u4ec5\u5f53 \u8bf7\u6c42\u6307\u5b9a \u3002<samp>metadata=LABELS<\/samp><\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>{\n  \"searchRecords\" : &#91; {\n    \"attributes\" : {\n      \"type\" : \"Account\",\n      \"url\" : \"\/services\/data\/v59.0\/sobjects\/Account\/001D000000IqhSLIAZ\"\n    },\n    \"Id\" : \"001D000000IqhSLIAZ\",\n  }, {\n    \"attributes\" : {\n      \"type\" : \"Account\",\n      \"url\" : \"\/services\/data\/v59.0\/sobjects\/Account\/001D000000IomazIAB\"\n    },\n    \"Id\" : \"001D000000IomazIAB\",\n  } ],\n  \"metadata\" : {\n    \"entityetadata\" : &#91; {\n      \"entityName\" : \"Account\",\n      \"fieldMetadata\" : &#91; {\n\n        \"name\" : \"Name\",\n        \"label\" : \"Account Name\"\n       } ]\n    } ]\n  }\n}<\/code><\/pre>\n\n\n\n<h2 class=\"wp-block-heading\">\u4f7f\u7528 POST \u65b9\u6cd5\u7684\u53c2\u6570\u5316\u641c\u7d22\u793a\u4f8b<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">\u6267\u884c\u4e00\u4e2a \u4f7f\u7528 POST \u65b9\u6cd5\u8fdb\u884c\u53c2\u6570\u5316\u641c\u7d22\uff0c\u4ee5\u8bbf\u95ee\u6240\u6709\u53ef\u7528\u7684\u641c\u7d22\u529f\u80fd\u3002\u793a\u4f8b\u7528\u6cd5<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>curl https:\/\/<em>MyDomainName<\/em>.my.salesforce.com\/services\/data\/v59.0\/parameterizedSearch \"Authorization: Bearer <em>token<\/em>\" -H \"Content-Type: application\/json\u201d -d \"@search.json\u201d<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">\u793a\u4f8b\u8bf7\u6c42\u6b63\u6587\u4e0d\u9700\u8981\u793a\u4f8b JSON \u6587\u4ef6<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>{\n    \"q\":\"Smith\",\n    \"fields\" : &#91;\"id\", \"firstName\", \"lastName\"],\n    \"sobjects\":&#91;{\"fields\":&#91;\"id\", \"NumberOfEmployees\"],\n\t          \"name\": \"Account\", \n\t          \"limit\":20},\n\t         {\"name\": \"Contact\"}],\n    \"in\":\"ALL\",\n    \"overallLimit\":100,\n    \"defaultLimit\":10\n}<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">\u793a\u4f8b\u54cd\u5e94\u6b63\u6587<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>{\n  \"searchRecords\" : &#91; {\n    \"attributes\" : {\n      \"type\" : \"Contact\",\n      \"url\" : \"\/services\/data\/v59.0\/sobjects\/Contact\/003xx000004TraiAAC\"\n    },\n    \"Id\" : \"003xx000004TraiAAC\",\n    \"FirstName\" : \"Smith\",\n    \"LastName\" : \"Johnson\"\n  }, {\n    \"attributes\" : {\n      \"type\" : \"Account\",\n      \"url\" : \"\/services\/data\/v59.0\/sobjects\/Account\/001xx000003DHXnAAO\"\n    },\n    \"Id\" : \"001xx000003DHXnAAO\",\n    \"NumberOfEmployees\" : 100\n  } ]\n}<\/code><\/pre>\n\n\n\n<h4 class=\"wp-block-heading\">\u53e6\u89c1<\/h4>\n\n\n\n<ul class=\"wp-block-list\">\n<li>\u641c\u7d22<\/li>\n\n\n\n<li>\u53c2\u6570\u5316\u641c\u7d22<\/li>\n<\/ul>\n\n\n\n<h2 class=\"wp-block-heading\">\u83b7\u53d6\u9ed8\u8ba4\u641c\u7d22\u8303\u56f4\u548c\u987a\u5e8f<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">\u4f7f\u7528\u201c\u641c\u7d22\u8303\u56f4\u548c\u987a\u5e8f\u201d\u8d44\u6e90\u68c0\u7d22 \u5df2\u767b\u5f55\u7528\u6237\uff0c\u5305\u62ec\u7528\u6237\u641c\u7d22\u7ed3\u679c\u4e2d\u7684\u4efb\u4f55\u56fa\u5b9a\u5bf9\u8c61 \u9875\u3002<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">\u5728\u4ee5\u4e0b\u793a\u4f8b\u4e2d\uff0c\u767b\u5f55\u7528\u6237\u7684\u9ed8\u8ba4\u5168\u5c40\u641c\u7d22\u8303\u56f4\u5305\u62ec \u7f51\u7ad9\u3001\u60f3\u6cd5\u3001\u6848\u4f8b\u3001\u5546\u673a\u3001\u5ba2\u6237\u548c\u7528\u6237\u5bf9\u8c61\uff0c\u6309\u4ee5\u4e0b\u987a\u5e8f\u6392\u5217 \u5b83\u4eec\u5728\u54cd\u5e94\u6b63\u6587\u4e2d\u8fd4\u56de\u3002\u793a\u4f8b\u7528\u6cd5<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>curl https:\/\/<em>MyDomainName<\/em>.my.salesforce.com\/services\/data\/v59.0\/search\/scopeOrder -H \"Authorization: Bearer <em>token<\/em>\"<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">\u793a\u4f8b\u8bf7\u6c42\u6b63\u6587\u4e0d\u9700\u8981\u793a\u4f8b\u54cd\u5e94\u6b63\u6587<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>&#91;\n  {\n    \"type\":\"Site\",\n    \"url\":\"\/services\/data\/v59.0\/sobjects\/Site\/describe\"\n  },\n  {\n    \"type\":\"Idea\",\n    \"url\":\"\/services\/data\/v59.0\/sobjects\/Idea\/describe\"\n  },\n  {\n    \"type\":\"Case\",\n    \"url\":\"\/services\/data\/v59.0\/sobjects\/Case\/describe\"\n  },\n  {\n    \"type\":\"Opportunity\",\n    \"url\":\"\/services\/data\/v59.0\/sobjects\/Opportunity\/describe\"\n  },\n  {\n    \"type\":\"Account\",\n    \"url\":\"\/services\/data\/v59.0\/sobjects\/Account\/describe\"\n  },\n  {\n    \"type\":\"User\",\n    \"url\":\"\/services\/data\/v59.0\/sobjects\/User\/describe\"\n  }\n]<\/code><\/pre>\n\n\n\n<h2 class=\"wp-block-heading\">\u83b7\u53d6\u5bf9\u8c61\u7684\u641c\u7d22\u7ed3\u679c\u5e03\u5c40<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">\u4f7f\u7528\u201c\u641c\u7d22\u7ed3\u679c\u5e03\u5c40\u201d\u8d44\u6e90\u68c0\u7d22\u6bcf\u4e2a\u5bf9\u8c61\u7684\u641c\u7d22\u7ed3\u679c\u5e03\u5c40\u914d\u7f6e \u5728\u67e5\u8be2\u5b57\u7b26\u4e32\u4e2d\u6307\u5b9a\u3002\u793a\u4f8b\u7528\u6cd5<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>curl https:\/\/<em>MyDomainName<\/em>.my.salesforce.com\/services\/data\/v59.0\/search\/layout\/?q=Account,Contact,Lead,Asset \"Authorization: Bearer <em>token<\/em>\"<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">\u793a\u4f8b\u8bf7\u6c42\u6b63\u6587\u4e0d\u9700\u8981\u793a\u4f8b\u54cd\u5e94\u6b63\u6587<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>&#91; { \"label\" : \"Search Results\",\n    \"limitRows\" : 25,\n    \"searchColumns\" : &#91; { \"field\" : \"Account.Name\",\n          \"format\" : null,\n          \"label\" : \"Account Name\",\n          \"name\" : \"Name\"\n        },\n        { \"field\" : \"Account.Site\",\n          \"format\" : null,\n          \"label\" : \"Account Site\",\n          \"name\" : \"Site\"\n        },\n        { \"field\" : \"Account.Phone\",\n          \"format\" : null,\n          \"label\" : \"Phone\",\n          \"name\" : \"Phone\"\n        },\n        { \"field\" : \"User.Alias\",\n          \"format\" : null,\n          \"label\" : \"Account Owner Alias\",\n          \"name\" : \"Owner.Alias\"\n        }\n      ]\n  },\n  { \"label\" : \"Search Results\",\n    \"limitRows\" : 25,\n    \"searchColumns\" : &#91; { \"field\" : \"Contact.Name\",\n          \"format\" : null,\n          \"label\" : \"Name\",\n          \"name\" : \"Name\"\n        },\n        { \"field\" : \"Account.Name\",\n          \"format\" : null,\n          \"label\" : \"Account Name\",\n          \"name\" : \"Account.Name\"\n        },\n        { \"field\" : \"Account.Site\",\n          \"format\" : null,\n          \"label\" : \"Account Site\",\n          \"name\" : \"Account.Site\"\n        },\n        { \"field\" : \"Contact.Phone\",\n          \"format\" : null,\n          \"label\" : \"Phone\",\n          \"name\" : \"Phone\"\n        },\n        { \"field\" : \"Contact.Email\",\n          \"format\" : null,\n          \"label\" : \"Email\",\n          \"name\" : \"Email\"\n        },\n        { \"field\" : \"User.Alias\",\n          \"format\" : null,\n          \"label\" : \"Contact Owner Alias\",\n          \"name\" : \"Owner.Alias\"\n        }\n      ]\n  },\n  { \"label\" : \"Search Results\",\n    \"limitRows\" : 25,\n    \"searchColumns\" : &#91; { \"field\" : \"Lead.Name\",\n          \"format\" : null,\n          \"label\" : \"Name\",\n          \"name\" : \"Name\"\n        },\n        { \"field\" : \"Lead.Title\",\n          \"format\" : null,\n          \"label\" : \"Title\",\n          \"name\" : \"Title\"\n        },\n        { \"field\" : \"Lead.Phone\",\n          \"format\" : null,\n          \"label\" : \"Phone\",\n          \"name\" : \"Phone\"\n        },\n        { \"field\" : \"Lead.Company\",\n          \"format\" : null,\n          \"label\" : \"Company\",\n          \"name\" : \"Company\"\n        },\n        { \"field\" : \"Lead.Email\",\n          \"format\" : null,\n          \"label\" : \"Email\",\n          \"name\" : \"Email\"\n        },\n        { \"field\" : \"Lead.Status\",\n          \"format\" : null,\n          \"label\" : \"Lead Status\",\n          \"name\" : \"toLabel(Status)\"\n        },\n        { \"field\" : \"Name.Alias\",\n          \"format\" : null,\n          \"label\" : \"Owner Alias\",\n          \"name\" : \"Owner.Alias\"\n        }\n      ]\n  },\n]<\/code><\/pre>\n\n\n\n<h2 class=\"wp-block-heading\">\u67e5\u770b\u76f8\u5173\u9879\u76ee<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">\u4f7f\u7528\u201c\u76f8\u5173\u9879\u76ee\u201d\u8d44\u6e90\u83b7\u53d6\u76f8\u5173\u9879\u76ee\u5217\u8868 \u8bb0\u5f55\u3002\u83b7\u53d6\u5f53\u524d\u7528\u6237\u6700\u76f8\u5173\u5217\u8868\u7684\u793a\u4f8b\u7528\u6cd5 \u8bb0\u5f55<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>curl https:\/\/<em>MyDomainName<\/em>.my.salesforce.com\/services\/data\/v59.0\/sobjects\/relevantItems -H \"Authorization: Bearer <em>token<\/em>\"<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">\u793a\u4f8b\u8bf7\u6c42\u6b63\u6587\u4e0d\u9700\u8981\u793a\u4f8b\u54cd\u5e94\u6b63\u6587<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>&#91; {\n    \"apiName\" : \"Contact\",\n    \"key\" : \"003\",\n    \"label\" : \"Contacts\",\n    \"lastUpdatedId\" : \"135866748\",\n    \"recordIds\" : &#91; \"003xx000004TxBA\" ]\n}, {   \"apiName\" : \"Account\",\n    \"key\" : \"001\",\n    \"label\" : \"Accounts\",\n    \"lastUpdatedId\" : \"193640553\",\n    \"recordIds\" : &#91; \"001xx000003DWsT\" ]\n}, {\n    \"apiName\" : \"User\",\n    \"key\" : \"005\",\n    \"label\" : \"Users\",\n    \"lastUpdatedId\" : \"-199920321\",\n    \"recordIds\" : &#91; \"005xx000001Svqw\", \"005xx000001SvwK\", \"005xx000001SvwA\" ]\n}, {  \"apiName\" : \"Case\",\n    \"key\" : \"069\",\n    \"label\" : \"Cases\",\n    \"lastUpdatedId\" : \"1033471693\",\n    \"recordIds\" : &#91; \"069xx0000000006\", \"069xx0000000001\", \"069xx0000000002\" ]\n} ]<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">\u7b5b\u9009\u5bf9\u7279\u5b9a\u5bf9\u8c61\u7684\u54cd\u5e94\u7684\u793a\u4f8b\u7528\u6cd5<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>curl https:\/\/<em>MyDomainName<\/em>.my.salesforce.com\/services\/data\/v59.0\/sobjects\/relevantItems?sobjects=Account,User -H \"Authorization: Bearer <em>token<\/em>\"<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">\u793a\u4f8b\u8bf7\u6c42\u6b63\u6587\u4e0d\u9700\u8981\u793a\u4f8b\u54cd\u5e94\u6b63\u6587<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>&#91; {\n    \"apiName\" : \"Account\",\n    \"key\" : \"001\",\n    \"label\" : \"Accounts\",\n    \"lastUpdatedId\" : \"193640553\",\n    \"recordIds\" : &#91; \"001xx000003DWsT\" ]\n}, {\n  \"apiName\" : \"User\",\n    \"key\" : \"005\",\n    \"label\" : \"Users\",\n    \"lastUpdatedId\" : \"102959935\",\n    \"recordIds\" : &#91; \"005xx000001Svqw\", \"005xx000001SvwK\", \"005xx000001SvwA\" ]\n} ]<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">\u5c06\u7528\u6237\u7684\u5f53\u524d\u76f8\u5173\u8bb0\u5f55\u5217\u8868\u4e0e \u4ee5\u524d\u7684\u7248\u672c<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>curl https:\/\/<em>MyDomainName<\/em>.my.salesforce.com\/services\/data\/v59.0\/sobjects\/relevantItems?lastUpdatedId=102959935 -H \"Authorization: Bearer <em>token<\/em>\"<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">\u793a\u4f8b\u8bf7\u6c42\u6b63\u6587\u4e0d\u9700\u8981\u793a\u4f8b\u54cd\u5e94\u6807\u5934<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>lastUpdatedId: 102959935\nnewResultSetSinceLastQuery: true<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">\u793a\u4f8b\u54cd\u5e94\u6b63\u6587<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>&#91; {\n    \"apiName\" : \"User\",\n    \"key\" : \"003\",\n    \"label\" : \"Users\",\n    \"lastUpdatedId\" : \"102959935\",\n    \"recordIds\" : &#91; \"003xx000004TxBA\" ]\n}, {\n    \"apiName\" : \"Account\",\n    \"key\" : \"001\",\n    \"label\" : \"Accounts\",\n    \"lastUpdatedId\" : \"193640553\",\n    \"recordIds\" : &#91; \"001xx000003DWsT\" ]\n}, {\n    \"apiName\" : \"Case\",\n    \"key\" : \"005\",\n    \"label\" : \"Cases\",\n  \"lastUpdatedId\" : \"1740766611\",\n    \"recordIds\" : &#91; \"005xx000001Svqw\", \"005xx000001SvwA\" ]\n} ]<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">\u5c06\u7528\u6237\u7684\u5f53\u524d\u76f8\u5173\u8bb0\u5f55\u5217\u8868\u4e0e \u7279\u5b9a\u5bf9\u8c61\u7684\u5148\u524d\u7248\u672c<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>curl https:\/\/<em>MyDomainName<\/em>.my.salesforce.com\/services\/data\/v59.0\/sobjects\/relevantItems?mode=MRU&amp;sobjects=Account,Contact&amp;Account.lastUpdatedId=102959935 -H \"Authorization: Bearer <em>token<\/em>\"<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">\u793a\u4f8b\u8bf7\u6c42\u6b63\u6587\u4e0d\u9700\u8981\u793a\u4f8b\u54cd\u5e94\u6b63\u6587<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>&#91; {\n    \"apiName\" : \"Account\",\n    \"key\" : \"001\",\n    \"label\" : \"Accounts\",\n    \"lastUpdatedId\" : \"193640553\",\n    \"recordIds\" : &#91; \"001xx000003DWsT\" ]\n} ]<\/code><\/pre>\n\n\n\n<h4 class=\"wp-block-heading\">\u53e6\u89c1<\/h4>\n\n\n\n<ul class=\"wp-block-list\">\n<li>sObject \u76f8\u5173\u9879\u76ee<\/li>\n<\/ul>\n\n\n\n<h2 class=\"wp-block-heading\">\u5220\u9664 Lightning Experience \u4e8b\u4ef6\u7cfb\u5217<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">\u4f7f\u7528 HTTP DELETE \u65b9\u6cd5\u5220\u9664\u5e8f\u5217\u4e2d\u7684\u4e00\u4e2a\u6216\u591a\u4e2a IsRecurrence2 \u4e8b\u4ef6\u3002\u4f60 \u53ef\u4ee5\u5220\u9664\u5355\u4e2a\u4e8b\u4ef6\u3001\u7279\u5b9a\u4e8b\u4ef6\u4e4b\u540e\u7684\u6240\u6709\u4e8b\u4ef6\uff08\u5305\u62ec\u7279\u5b9a\u4e8b\u4ef6\uff09\u6216\u6574\u4e2a\u4e8b\u4ef6 \u7cfb\u5217\u3002<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">\u5220\u9664\u5e8f\u5217\u4e2d\u7684\u5355\u4e2a\u4e8b\u4ef6<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">\u4f7f\u7528&nbsp;sObject Rows&nbsp;\u8d44\u6e90\u5220\u9664\u4e8b\u4ef6\u8bb0\u5f55\u3002\u5220\u9664 \u7cfb\u5217\u4e2d\uff0c\u6307\u5b9a\u4e8b\u4ef6 ID \u5e76\u4f7f\u7528\u8d44\u6e90\u6765\u5220\u9664\u8bb0\u5f55\u3002<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">\u4ece\u7cfb\u5217\u4e2d\u5220\u9664\u591a\u4e2a\u4e8b\u4ef6\u6216\u6240\u6709\u4e8b\u4ef6<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">\u82e5\u8981\u5220\u9664\u5e8f\u5217\u4e2d\u7279\u5b9a\u4e8b\u4ef6\u53ca\u4ee5\u540e\u7684\u6240\u6709\u4e8b\u4ef6\uff0c\u8bf7\u6307\u5b9a\u4e8b\u4ef6 ID \u5e76\u4f7f\u7528\u8d44\u6e90\u7684 DELETE \u65b9\u6cd5\u5220\u9664\u8bb0\u5f55\u3002\u8c03\u7528\u6b64\u65b9\u6cd5\u65f6\uff0c IsRecurrence2 \u5fc5\u987b\u4e3a true\uff0cIsRecurrence2Exclusion \u5fc5\u987b\u4e3a false\u3002<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">\u82e5\u8981\u5220\u9664\u6574\u4e2a\u4e8b\u4ef6\u7cfb\u5217\uff0c\u8bf7\u6307\u5b9a\u8be5\u7cfb\u5217\u4e2d\u7b2c\u4e00\u4e2a\u4e8b\u4ef6\u7684\u4e8b\u4ef6 ID \u5e76\u4f7f\u7528\u8d44\u6e90\u7684 DELETE \u65b9\u6cd5\u5220\u9664\u8bb0\u5f55\u3002\u4ece\u7cfb\u5217\u4e2d\u5220\u9664\u591a\u4e2a\u4e8b\u4ef6\u6216\u6240\u6709\u4e8b\u4ef6\u7684\u793a\u4f8b<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>curl https:\/\/<em>MyDomainName<\/em>.my.salesforce.com\/services\/data\/v59.0\/sobjects\/Event\/00Uxx0000000000\/fromThisEventOnwards -H \"Authorization: Bearer <em>token<\/em>\" -X DELETE<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">\u793a\u4f8b\u8bf7\u6c42\u6b63\u6587<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>None needed<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">\u6210\u529f\u5220\u9664\u4e8b\u4ef6\u540e\u7684\u793a\u4f8b\u54cd\u5e94\u6b63\u6587<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>{\nsuccess: We\u2019re deleting the selected events from the series. Wait for all events to be removed. \n}<\/code><\/pre>\n\n\n\n<h2 class=\"wp-block-heading\">\u8003\u8651<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">\u4ece\u4e8b\u4ef6\u4e2d\u5220\u9664\u4e0d\u652f\u6301\u6765\u81ea\u4ee5\u4e0b\u4e8b\u4ef6\u7684\u8c03\u7528\uff1a<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>\u53d1\u751f\u5728 Recurrence2PatternStartDate \u7684\u539f\u59cb\u503c\u4e4b\u524d\u3002<\/li>\n\n\n\n<li>\u5b9a\u4e49\u4e3a\u5b50\u4e8b\u4ef6\u3002<\/li>\n<\/ul>\n\n\n\n<p class=\"wp-block-paragraph\">\u5982\u679c\u4e8b\u4ef6\u7cfb\u5217\u6e90\u81ea Salesforce \u5916\u90e8\uff0c\u5e76\u4e14\u4e8b\u4ef6 ID \u4e3a\u7b2c\u4e00\u6b21 \u4e0d\u53ef\u7528\uff0c\u5219\u65e0\u6cd5\u5220\u9664\u7cfb\u5217\u4e2d\u7684\u6240\u6709\u4e8b\u4ef6\u3002\u76f8\u53cd\uff0c\u8bf7\u4ece\u7279\u5b9a \u53d1\u751f\u3002<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">\u4ece\u5bcc\u6587\u672c\u533a\u57df\u5b57\u6bb5\u83b7\u53d6\u56fe\u50cf<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">\u4f7f\u7528 sObject \u5bcc\u6587\u672c\u56fe\u50cf\u83b7\u53d6\u8d44\u6e90\u4ece\u5bcc\u6587\u672c\u533a\u57df\u5b57\u6bb5\u4e2d\u68c0\u7d22\u56fe\u50cf\u3002\u5728\u8fd9\u4e2a\u4f8b\u5b50\u4e2d\uff0c\u6211\u4eec \u4ece\u540d\u4e3a \u7684\u6f5c\u5728\u5ba2\u6237\u8bb0\u5f55\u7684\u81ea\u5b9a\u4e49\u5bcc\u6587\u672c\u5b57\u6bb5\u4e2d\u68c0\u7d22\u56fe\u50cf\u3002\u6211\u4eec\u5047\u8bbe\u56fe\u50cf\u5df2\u7ecf \u4e0a\u4f20\u5230\u6b64\u5b57\u6bb5\u3002<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><samp>LeadPhotoRichText__c<\/samp><\/p>\n\n\n\n<h2 class=\"wp-block-heading\">\u83b7\u53d6\u955c\u50cf\u5f15\u7528 ID<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">\u5728\u901a\u8fc7\u8bf7\u6c42\u68c0\u7d22\u56fe\u50cf\u4e4b\u524d\uff0c\u5fc5\u987b\u5148\u4ece\u5bcc\u6587\u672c\u5b57\u6bb5\u4e2d\u83b7\u53d6\u56fe\u50cf\u3002\u4f7f\u7528\u00a0sObject Rows\u00a0\u8d44\u6e90\u68c0\u7d22 \u6f5c\u5728\u987e\u5ba2\u8bb0\u5f55\u7684\u5b57\u6bb5\u4fe1\u606f\u3002<samp>refid<\/samp><\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>curl https:\/\/<em>MyDomainName<\/em>.my.salesforce.com\/services\/data\/v59.0\/sobjects\/Lead\/00Q112222233333 -H \"Authorization: Bearer <em>token<\/em>\"<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">\u4e0b\u9762\u662f\u8bf7\u6c42\u7684\u7cbe\u7b80\u8f93\u51fa\u793a\u4f8b\u3002<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>{\n    \"attributes\": {\n        \"type\": \"Lead\",\n        \"url\": \"\/services\/data\/v51.0\/sobjects\/Lead\/00Q112222233333\"\n    },\n    \"Id\": \"00Q112222233333\",\n    \"IsDeleted\": false,\n    \"MasterRecordId\": null,\n    \"LastName\": \"Smith\",\n    \"FirstName\": \"John\",\n\n    ...\n\n    \"LeadPhotoRichText__c\": \"&lt;img alt=\\\"johnSmithPhoto\\\" src=\\\"https:\/\/<em>MyDomainName<\/em>.documentforce.com\/servlet\/rtaImage?eid=a005e000007Dksm&amp;amp;feoid=00N5e00000djU6Y&amp;amp;refid=0EM5e000000B9LQ\\\"&gt;&lt;\/img&gt;\"\n}<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">\u4eceLeadPhotoRichText__c\u5b57\u6bb5\u4e2d\u53ef\u4ee5\u770b\u51fa\uff0c\u56fe\u50cf\u7684 \u662f \u3002\u4f7f\u7528\u8fd9\u4e2a \u503c\u4ee5\u68c0\u7d22\u56fe\u50cf\u3002<samp>refid<\/samp><samp>0EM5e000000B9LQ<\/samp><\/p>\n\n\n\n<h2 class=\"wp-block-heading\">\u68c0\u7d22\u56fe\u50cf<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">\u4f7f\u7528\u6f5c\u5728\u987e\u5ba2\u8bb0\u5f55 ID\u3001\u5bcc\u6587\u672c\u5b57\u6bb5\u540d\u79f0\u548c\u56fe\u50cf\u68c0\u7d22\u56fe\u50cf\u3002\u54cd\u5e94\u5c06\u56fe\u50cf\u4f5c\u4e3a\u7f16\u7801\u6570\u636e\u8fd4\u56de\uff0c\u5e76\u4f7f\u7528 \u4e0e\u4e0a\u4f20\u65f6\u4f7f\u7528\u7684\u6587\u4ef6\u7c7b\u578b\u76f8\u540c\u3002\u5c06\u8fd4\u56de\u7684\u6570\u636e\u53e6\u5b58\u4e3a\u56fe\u50cf\u6587\u4ef6\uff0c\u5e76\u4f7f\u7528 \u4f7f\u7528\u53c2\u6570\u7684\u9002\u5f53\u6587\u4ef6\u7c7b\u578b\u3002<samp>refid<\/samp><samp>&#8211;output&nbsp;<var>filename<\/var><\/samp><\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>curl https:\/\/<em>MyDomainName<\/em>.my.salesforce.com\/services\/data\/v59.0\/sobjects\/Lead\/00Q112222233333\/richTextImageFields\/LeadPhotoRichText__c\/0EMR00000000A8V -H \"Authorization: Bearer <em>token<\/em>\" --output \"LeadPhoto.jpeg\"<\/code><\/pre>\n\n\n\n<h2 class=\"wp-block-heading\">\u63d2\u5165\u6216\u66f4\u65b0 Blob \u6570\u636e<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">\u60a8\u53ef\u4ee5\u4f7f\u7528\u00a0sObject \u57fa\u672c\u4fe1\u606f\u3001sObject\u00a0\u884c\u6216 sObject\u00a0\u8981\u5728\u5176\u4e2d\u63d2\u5165\u6216\u66f4\u65b0\u4e8c\u8fdb\u5236\u5927\u578b\u5bf9\u8c61 \uff08blob\uff09 \u7684\u96c6\u5408\u8d44\u6e90 Salesforce\uff0c\u4f8b\u5982\u56fe\u50cf\u6216 PDF\u3002\u60a8\u53ef\u4ee5\u5c06\u4efb\u4f55\u7c7b\u578b\u7684\u6587\u4ef6\u6216\u4e8c\u8fdb\u5236\u6570\u636e\u4e0a\u4f20\u5230 \u5305\u542b blob \u5b57\u6bb5\u7684\u4efb\u4f55\u6807\u51c6\u5bf9\u8c61\u3002<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">\u82e5\u8981\u63d2\u5165\u548c\u66f4\u65b0 blob \u6570\u636e\uff0c\u8bf7\u521b\u5efa\u591a\u90e8\u5206\u8bf7\u6c42\u6b63\u6587\u3002\u7b2c\u4e00\u90e8\u5206 \u8bf7\u6c42\u6b63\u6587\u5305\u542b\u975e\u4e8c\u8fdb\u5236\u5b57\u6bb5\u6570\u636e\uff0c\u4f8b\u5982\u65b0\u5b57\u6bb5\u7684\u63cf\u8ff0\u6216\u540d\u79f0 \u8bb0\u5f55\u3002\u7b2c\u4e8c\u90e8\u5206\u5305\u542b\u60a8\u8981\u4e0a\u4f20\u7684\u6587\u4ef6\u7684\u4e8c\u8fdb\u5236\u6570\u636e\u3002\u8fd9 \u8bf7\u6c42\u6b63\u6587\u5fc5\u987b\u7b26\u5408 MIME \u591a\u90e8\u5206\u5185\u5bb9\u7c7b\u578b\u6807\u51c6\u3002\u67e5\u770b\u66f4\u591a \u4fe1\u606f\uff0c\u8bf7\u53c2\u9605\u591a\u90e8\u5206\u5185\u5bb9\u7c7b\u578b\u7684 W3C \u6807\u51c6\u3002<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">\u5982\u679c\u4f7f\u7528 sObject \u57fa\u672c\u4fe1\u606f\u6216 sObject \u884c\u8d44\u6e90\uff0c\u5219 ContentVersion \u5bf9\u8c61\u548c \u5bf9\u4e8e\u6240\u6709\u5176\u4ed6\u7b26\u5408\u6761\u4ef6\u7684\u6807\u51c6\u5bf9\u8c61\uff0c\u4e3a 500 MB\u3002\u5982\u679c\u4f7f\u7528 sObject \u96c6\u5408 \u8d44\u6e90\uff0c\u5219\u5355\u4e2a\u8bf7\u6c42\u4e2d\u6240\u6709\u6587\u4ef6\u7684\u6700\u5927\u603b\u5927\u5c0f\u4e3a 500 MB\u3002<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">\u6ce8\u610f<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">\u53ef\u4ee5\u4f7f\u7528\u975e\u591a\u90e8\u5206\u6d88\u606f\u63d2\u5165\u6216\u66f4\u65b0 blob \u6570\u636e\uff0c\u4f46\u53d7\u5230\u9650\u5236 \u5230 50 MB \u7684\u6587\u672c\u6570\u636e\u6216 37.5 MB \u7684 base64 \u7f16\u7801\u6570\u636e\u3002<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">\u8fd9\u4e9b\u90e8\u5206\u63d0\u4f9b\u4e86\u5982\u4f55\u4f7f\u7528\u591a\u90e8\u5206\u63d2\u5165\u6216\u66f4\u65b0 blob \u6570\u636e\u7684\u793a\u4f8b content-type \u8bf7\u6c42\u3002\u8fd9\u4e9b\u793a\u4f8b\u7684\u8bf7\u6c42\u6b63\u6587\u4f7f\u7528 JSON \u683c\u5f0f\u3002<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">\u63d2\u5165\u5305\u542b Blob \u6570\u636e\u7684\u6587\u6863<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">\u6b64\u793a\u4f8b\u8bf7\u6c42\u548c\u8bf7\u6c42\u6b63\u6587\u521b\u5efa\u4e00\u4e2a Document \u8bb0\u5f55\uff0c\u5176\u4e2d\u5305\u542b PDF \u6587\u4ef6\u7684\u4e8c\u8fdb\u5236\u6570\u636e\u3002\u9664\u4e86\u6587\u4ef6\u672c\u8eab\u7684\u4e8c\u8fdb\u5236\u6570\u636e\u5916\uff0c request body \u8fd8\u6307\u5b9a\u5176\u4ed6\u5b57\u6bb5\u6570\u636e\uff0c\u5305\u62ec Document \u5bf9\u8c61\u6240\u9700\u7684&nbsp;FolderId\u3002<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">\u5982\u679c\u60a8\u5728 Salesforce \u4e2d\u6ca1\u6709\u65b0\u6587\u6863\u8bb0\u5f55\u7684\u6587\u4ef6\u5939\u8bb0\u5f55\uff0c\u5219\u5fc5\u987b \u4f7f\u7528 sObject \u57fa\u672c\u4fe1\u606f\u8d44\u6e90\u521b\u5efa\u4e00\u4e2a\uff0c\u7136\u540e\u624d\u80fd\u9075\u5faa\u6b64\u64cd\u4f5c \u4f8b\u3002\u786e\u4fdd\u201c\u6587\u4ef6\u5939\u201d\u8bb0\u5f55\u7684\u201c\u7c7b\u578b\u201d\u5b57\u6bb5\u4e3a \u516c\u6587\u3002<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">\u63d0\u793a<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">\u6210\u529f\u53d1\u9001\u8bf7\u6c42\u540e\uff0c\u60a8\u53ef\u4ee5\u67e5\u770b\u65b0\u6587\u6863 \u5728 Salesforce Classic \u4e2d\u3002Salesforce Lightning \u4e0d\u4f1a\u5728\u7528\u6237\u4e2d\u663e\u793a\u6587\u6863 \u63a5\u53e3\u3002\u521b\u5efa\u6587\u6863\u7684\u793a\u4f8b\u8bf7\u6c42<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>curl https:\/\/<em>MyDomainName<\/em>.my.salesforce.com\/services\/data\/v59.0\/sobjects\/Document\/ -H \"Authorization: Bearer <em>token<\/em>\" -H \"Content-Type: multipart\/form-data; boundary=\\\"boundary_string\\\"\" --data-binary @NewDocument.json<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">\u7528\u4e8e\u521b\u5efa\u6587\u6863\u7684\u793a\u4f8b\u8bf7\u6c42\u6b63\u6587\u6b64\u8bf7\u6c42\u6b63\u6587\u8868\u793a&nbsp;NewDocument.json&nbsp;\u7684\u5185\u5bb9\u3002PDF \u7684\u4e8c\u8fdb\u5236\u6570\u636e \u4e3a\u7b80\u6d01\u8d77\u89c1\uff0c\u7701\u7565\u4e86\u5185\u5bb9\uff0c\u5e76\u66ff\u6362\u4e3a\u201c\u4e8c\u8fdb\u5236\u6570\u636e\u201d \u53bb\u8fd9\u91cc\u3002\u5b9e\u9645\u8bf7\u6c42\u5305\u542b\u5b8c\u6574\u7684\u4e8c\u8fdb\u5236\u6587\u4ef6 \u5185\u5bb9\u3002<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>--boundary_string\nContent-Disposition: form-data; name=\"entity_document\";\nContent-Type: application\/json\n\n{  \n    \"Description\" : \"Marketing brochure for Q1 2011\",\n    \"Keywords\" : \"marketing,sales,update\",\n    \"FolderId\" : \"005D0000001GiU7\",\n    \"Name\" : \"Marketing Brochure Q1\",\n    \"Type\" : \"pdf\"\n}\n\n--boundary_string\nContent-Type: application\/pdf\nContent-Disposition: form-data; name=\"Body\"; filename=\"2011Q1MktgBrochure.pdf\"\n\nBinary data goes here.\n\n--boundary_string--<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">\u793a\u4f8b\u54cd\u5e94\u6b63\u6587\u6210\u529f\u540e\uff0c\u65b0\u6587\u6863\u7684&nbsp;ID&nbsp;\u4e3a \u8fd4\u56de\u3002<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>{\n    \"id\" : \"015D0000000N3ZZIA0\",\n    \"errors\" : &#91; ],\n    \"success\" : true\n}<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">\u9519\u8bef\u54cd\u5e94\u793a\u4f8b<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>{\n    \"fields\" : &#91; \"FolderId\" ],\n    \"message\" : \"Folder ID: id value of incorrect type: 005D0000001GiU7\",\n    \"errorCode\" : \"MALFORMED_ID\"\n}<\/code><\/pre>\n\n\n\n<h2 class=\"wp-block-heading\">\u4f7f\u7528 Blob \u6570\u636e\u66f4\u65b0\u6587\u6863<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">\u672c\u793a\u4f8b\u66f4\u65b0\u73b0\u6709 Document \u8bb0\u5f55\u3002\u6839\u636e \u8bf7\u6c42\u6b63\u6587\uff0c\u53ef\u4ee5\u66f4\u65b0\u8bb0\u5f55\u7684\u5b57\u6bb5\uff0c\u5173\u8054\u4e8c\u8fdb\u5236\u6570\u636e \u6709\u4e86\u5b83\uff0c\u6216\u4e24\u8005\u517c\u800c\u6709\u4e4b\u3002<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">\u5982\u679c\u53ea\u60f3\u66f4\u65b0\u8bb0\u5f55\u5b57\u6bb5\uff0c\u5219\u8bf7\u6c42\u6b63\u6587\u4e0d\u9700\u8981 \u591a\u90e8\u5206\u5185\u5bb9\u7c7b\u578b\u3002\u66f4\u65b0 Document \u5bf9\u8c61\u4e2d\u7684\u4e8c\u8fdb\u5236\u6570\u636e\u7684\u793a\u4f8b\u8bf7\u6c42<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>curl https:\/\/<em>MyDomainName<\/em>.my.salesforce.com\/services\/data\/v59.0\/Document\/015D0000000N3ZZIA0 -H \"Authorization: Bearer <em>token<\/em>\" -H \"Content-Type: multipart\/form-data; boundary=\\\"boundary_string\\\"\" --data-binary @UpdateDocument.json -X PATCH<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">\u7528\u4e8e\u66f4\u65b0 Document \u5bf9\u8c61\u4e2d\u7684\u4e8c\u8fdb\u5236\u6570\u636e\u7684\u793a\u4f8b\u8bf7\u6c42\u6b63\u6587<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">\u6b64\u8bf7\u6c42\u6b63\u6587\u8868\u793a&nbsp;UpdateDocument.json&nbsp;\u7684\u5185\u5bb9\u3002\u6b64\u793a\u4f8b\u66f4\u65b0 \u8bb0\u5f55\u7684\u4e8c\u8fdb\u5236\u6570\u636e\uff0c\u4ee5\u53ca\u201c\u540d\u79f0\u201d\u548c\u201c\u5173\u952e\u5b57\u201d\u5b57\u6bb5\u3002\u5982\u679c\u60a8\u53ea\u60f3\u66f4\u65b0 \u4e8c\u8fdb\u5236\u6570\u636e\uff0c\u60a8\u53ef\u4ee5\u5220\u9664\u5e26\u6709&nbsp;Name&nbsp;\u548c&nbsp;Keywords&nbsp;\u5b57\u6bb5\u7684\u4ee3\u7801\u884c\u3002<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">\u4e3a\u7b80\u6d01\u8d77\u89c1\uff0c\u7701\u7565\u4e86 PDF \u5185\u5bb9\u7684\u4e8c\u8fdb\u5236\u6570\u636e\uff0c\u5e76\u4e14 \u66ff\u6362\u4e3a\u201c\u66f4\u65b0\u7684\u6587\u6863\u4e8c\u8fdb\u5236\u6587\u4ef6\u8f6c\u5230\u6b64\u5904\u201d\u3002\u4e00 \u5b9e\u9645\u8bf7\u6c42\u5305\u542b\u5b8c\u6574\u7684\u4e8c\u8fdb\u5236\u5185\u5bb9\u3002<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>--boundary_string\nContent-Disposition: form-data; name=\"entity_content\";\nContent-Type: application\/json\n\n{  \n    \"Name\" : \"Marketing Brochure Q1 - Sales\",\n    \"Keywords\" : \"sales, marketing, first quarter\"\n}\n\n--boundary_string\nContent-Type: application\/pdf\nContent-Disposition: form-data; name=\"Body\"; filename=\"2011Q1MktgBrochure.pdf\"\n\nUpdated document binary data goes here.\n\n--boundary_string--<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">\u7528\u4e8e\u66f4\u65b0 Document \u5bf9\u8c61\u4e2d\u7684\u5b57\u6bb5\u7684\u793a\u4f8b\u54cd\u5e94\u6b63\u6587\u65e0\u8fd4\u56de\u9519\u8bef\u54cd\u5e94\u8bf7\u53c2\u9605\u72b6\u6001\u4ee3\u7801\u548c\u9519\u8bef\u54cd\u5e94\u3002<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">\u63d2\u5165 ContentVersion<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">\u6b64\u793a\u4f8b\u63d2\u5165\u4e00\u4e2a\u65b0\u7684 ContentVersion\u3002\u9664\u4e86\u6587\u4ef6\u7684\u4e8c\u8fdb\u5236\u6570\u636e \u672c\u8eab\uff0c\u6b64\u4ee3\u7801\u8fd8\u4e3a\u5176\u4ed6\u5b57\u6bb5\uff08\u5982&nbsp;ReasonForChange&nbsp;\u548c&nbsp;PathOnClient\uff09\u63d0\u4f9b\u503c\u3002\u8fd9 message \u5305\u542b&nbsp;ContentDocumentId\uff0c\u56e0\u4e3a ContentVersion \u59cb\u7ec8\u4e0e ContentDocument \u76f8\u5173\u8054\u3002<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">\u63d0\u793a<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">ContentVersion \u5bf9\u8c61\u4e0d\u652f\u6301\u66f4\u65b0\u3002\u56e0\u6b64\uff0c\u4f60\u4e0d\u80fd \u66f4\u65b0 ContentVersion\u3002\u60a8\u53ea\u80fd\u63d2\u5165\u65b0\u7684 ContentVersion\u3002\u60a8\u53ef\u4ee5\u770b\u5230 \u5185\u5bb9\u9009\u9879\u5361\u4e0a\u7684\u66f4\u6539\u7ed3\u679c\u3002\u63d2\u5165 ContentVersion \u7684\u793a\u4f8b\u7528\u6cd5<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>curl https:\/\/<em>MyDomainName<\/em>.my.salesforce.com\/services\/data\/v59.0\/sobjects\/ContentVersion -H \"Authorization: Bearer <em>token<\/em>\" -H \"Content-Type: multipart\/form-data; boundary=\\\"boundary_string\\\"\" --data-binary @NewContentVersion.json<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">\u7528\u4e8e\u63d2\u5165 ContentVersion \u7684\u793a\u4f8b\u8bf7\u6c42\u6b63\u6587<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">\u6b64\u8bf7\u6c42\u6b63\u6587\u8868\u793a\u6587\u4ef6&nbsp;NewContentVersion.json&nbsp;\u7684\u5185\u5bb9\u3002\u4e8c\u8fdb\u5236\u6570\u636e \u4e3a\u7b80\u6d01\u8d77\u89c1\uff0c\u7701\u7565\u4e86 PDF \u5185\u5bb9\uff0c\u5e76\u66ff\u6362\u4e3a \u201c\u4e8c\u8fdb\u5236\u6570\u636e\u5728\u8fd9\u91cc\u3002\u201d\u5b9e\u9645\u8bf7\u6c42\u5305\u542b \u5b8c\u6574\u7684\u4e8c\u8fdb\u5236\u5185\u5bb9\u3002<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>--boundary_string\nContent-Disposition: form-data; name=\"entity_content\";\nContent-Type: application\/json\n\n{\n    \"ContentDocumentId\" : \"069D00000000so2\",\n    \"ReasonForChange\" : \"Marketing materials updated\",\n    \"PathOnClient\" : \"Q1 Sales Brochure.pdf\"\n}\n\n--boundary_string\nContent-Type: application\/octet-stream\nContent-Disposition: form-data; name=\"VersionData\"; filename=\"Q1 Sales Brochure.pdf\"\n\nBinary data goes here.\n\n--boundary_string--<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">\u63d2\u5165 ContentVersion \u7684\u793a\u4f8b\u54cd\u5e94\u6b63\u6587<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>{\n    \"id\" : \"068D00000000pgOIAQ\",\n    \"errors\" : &#91; ],\n    \"success\" : true\n}<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">\u63d2\u5165 ContentVersion \u7684\u9519\u8bef\u54cd\u5e94\u8bf7\u53c2\u9605\u72b6\u6001\u4ee3\u7801\u548c\u9519\u8bef\u54cd\u5e94\u3002<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">\u4f7f\u7528 sObject \u96c6\u5408\u63d2\u5165 Blob \u8bb0\u5f55\u7684\u96c6\u5408<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">\u672c\u793a\u4f8b\u63d2\u5165\u65b0\u6587\u6863\u7684\u96c6\u5408\u3002\u9664\u4e86\u4e8c\u8fdb\u5236\u6570\u636e \u6587\u4ef6\u672c\u8eab\uff0c\u6b64\u4ee3\u7801\u8fd8\u6307\u5b9a\u5176\u4ed6\u5b57\u6bb5\u6570\u636e\uff0c\u4f8b\u5982\u6bcf\u6761\u8bb0\u5f55\u7684&nbsp;Description&nbsp;\u548c&nbsp;Name&nbsp;\u5728\u96c6\u5408\u4e2d\u3002<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">\u63d0\u793a<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">\u6210\u529f\u53d1\u9001\u8bf7\u6c42\u540e\uff0c\u60a8\u53ef\u4ee5\u67e5\u770b\u65b0\u6587\u6863 \u5728 Salesforce Classic \u4e2d\u3002Salesforce Lightning \u4e0d\u4f1a\u5728\u7528\u6237\u4e2d\u663e\u793a\u6587\u6863 \u63a5\u53e3\u3002\u5c5e\u6027\u5982\u679c\u5c06 sObject \u96c6\u5408\u7528\u4e8e blob \u6570\u636e\uff0c\u5219\u5fc5\u987b\u6307\u5b9a\u67d0\u4e9b \u9664 in \u4e4b\u5916\u7684\u5c5e\u6027\u503c \u8bf7\u6c42\u6b63\u6587\u7684\u5c5e\u6027\u6620\u5c04\u3002<samp>type<\/samp><\/p>\n\n\n\n<figure class=\"wp-block-table\"><table><thead><tr><th>\u53c2\u6570<\/th><th>\u63cf\u8ff0<\/th><\/tr><\/thead><tbody><tr><td>binaryPartName<\/td><td>\u5bf9\u4e8e blob \u6570\u636e\u662f\u5fc5\u9700\u7684\u3002\u7684\u552f\u4e00\u6807\u8bc6\u7b26 \u4e8c\u8fdb\u5236\u90e8\u5206\u3002<\/td><\/tr><tr><td>binaryPartName\u522b\u540d<\/td><td>\u5bf9\u4e8e blob \u6570\u636e\u662f\u5fc5\u9700\u7684\u3002\u4e2d\u5b57\u6bb5\u7684\u540d\u79f0 \u63d2\u5165\u6216\u66f4\u65b0\u4e8c\u8fdb\u5236\u6570\u636e\u3002<\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">\u521b\u5efa\u6587\u6863\u7684\u793a\u4f8b<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>curl https:\/\/<em>MyDomainName<\/em>.my.salesforce.com\/services\/data\/v59.0\/composite\/sobjects\/ -H \"Authorization: Bearer <em>token<\/em>\" -H \"Content-Type: multipart\/form-data; boundary=\\\"boundary_string\\\"\" --data-binary @newdocuments.json<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">\u7528\u4e8e\u521b\u5efa\u6587\u6863\u7684\u793a\u4f8b\u8bf7\u6c42\u6b63\u6587\u6b64\u4ee3\u7801\u662f&nbsp;newdocuments.json&nbsp;\u7684\u5185\u5bb9\u3002\u8fd9 \u4e3a\u7b80\u6d01\u8d77\u89c1\uff0c\u7701\u7565\u4e86 PDF \u5185\u5bb9\u7684\u4e8c\u8fdb\u5236\u6570\u636e\u5e76\u8fdb\u884c\u4e86\u66ff\u6362 \u66ff\u6362\u4e3a\u201c\u4e8c\u8fdb\u5236\u6570\u636e\u5728\u8fd9\u91cc\u201d\u3002\u5b9e\u9645\u8bf7\u6c42\u5305\u542b \u5b8c\u6574\u4e8c\u8fdb\u5236 \u5185\u5bb9\u3002<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>--boundary_string\nContent-Disposition: form-data; name=\"collection\"\nContent-Type: application\/json\n\n{\n    \"allOrNone\" : false,\n    \"records\" :\n    &#91;\n        {\n            \"attributes\" :\n            {\n                \"type\" : \"Document\",\n                \"binaryPartName\": \"binaryPart1\",\n                \"binaryPartNameAlias\": \"Body\"\n            },\n            \"Description\" : \"Marketing Brochure\",\n            \"FolderId\" : \"005xx000001Svs4AAC\",\n            \"Name\" : \"Brochure\",\n            \"Type\" : \"pdf\"\n        },\n        {\n            \"attributes\" :\n            {\n                \"type\" : \"Document\",\n                \"binaryPartName\": \"binaryPart2\",\n                \"binaryPartNameAlias\": \"Body\"\n            },\n            \"Description\" : \"Pricing Overview\",\n            \"FolderId\" : \"005xx000001Svs4AAC\",\n            \"Name\" : \"Pricing\",\n            \"Type\" : \"pdf\"\n        }\n    ]\n}\n\n--boundary_string\nContent-Disposition: form-data; name=\"binaryPart1\"; filename=\"Brochure.pdf\"\nContent-Type: application\/pdf\n\nBinary data goes here.\n\n--boundary_string\nContent-Disposition: form-data; name=\"binaryPart2\"; filename=\"Pricing.pdf\"\nContent-Type: application\/pdf\n\nBinary data goes here.\n\n--boundary_string--<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">\u7528\u4e8e\u521b\u5efa\u6587\u6863\u7684\u793a\u4f8b\u54cd\u5e94\u6b63\u6587\u6210\u529f\u540e\uff0c\u65b0\u6587\u6863\u7684 ID \u4e3a \u8fd4\u56de\u3002<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>&#91;\n    {\n        \"id\": \"015xx00000013QjAAI\",\n        \"errors\": &#91;],\n        \"success\": true\n    },\n    {\n        \"id\": \"015xx00000013QkAAI\",\n        \"errors\": &#91;],\n        \"success\": true\n    }\n]<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">\u6709\u5173\u66f4\u591a\u4fe1\u606f\uff0c\u8bf7\u53c2\u89c1\u00a0sObject \u96c6\u5408\u3002<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">\u591a\u90e8\u5206\u6d88\u606f\u6ce8\u610f\u4e8b\u9879<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">\u4ee5\u4e0b\u662f\u591a\u90e8\u5206\u6d88\u606f\u683c\u5f0f\u7684\u4e00\u4e9b\u6ce8\u610f\u4e8b\u9879\uff0c\u5f53\u60a8 \u63d2\u5165\u6216\u66f4\u65b0 blob \u6570\u636e\u3002\u8fb9\u754c\u5b57\u7b26\u4e32<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>\u5206\u9694\u591a\u90e8\u5206\u8bf7\u6c42\u6b63\u6587\u7684\u5404\u4e2a\u90e8\u5206\u3002<\/li>\n\n\n\n<li>\u5fc5\u987b\u5728\u5206\u6bb5\u8bf7\u6c42\u7684\u6807\u5934\u4e2d\u6307\u5b9a\u3002<samp>Content-Type<\/samp><\/li>\n\n\n\n<li>\u6700\u591a\u53ef\u5305\u542b 70 \u4e2a\u5b57\u7b26\u3002<\/li>\n\n\n\n<li>\u4e0d\u80fd\u662f\u51fa\u73b0\u5728 \u8bf7\u6c42\u6b63\u6587\u3002<\/li>\n\n\n\n<li>\u5305\u62ec\u7b2c\u4e00\u4e2a\u8fb9\u754c\u7684\u4e24\u4e2a\u8fde\u5b57\u7b26 \uff08&#8211;\uff09 \u524d\u7f00 \u5b57\u7b26\u4e32\u3002<\/li>\n\n\n\n<li>\u5305\u62ec\u6700\u540e\u4e00\u4e2a\u8fb9\u754c\u5b57\u7b26\u4e32\u7684\u4e24\u4e2a\u8fde\u5b57\u7b26 \uff08&#8211;\uff09 \u540e\u7f00\u3002<\/li>\n<\/ul>\n\n\n\n<p class=\"wp-block-paragraph\">Content-Disposition \u6807\u5934<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>\u5728\u8bf7\u6c42\u6b63\u6587\u7684\u6bcf\u4e2a\u90e8\u5206\u4e2d\u662f\u5fc5\u9700\u7684\u3002<\/li>\n\n\n\n<li>\u5fc5\u987b\u4f5c\u4e3a\u503c \u548c\u5c5e\u6027\u3002<samp>form-data<\/samp><samp>name<\/samp>\n<ul class=\"wp-block-list\">\n<li>\u5728\u8bf7\u6c42\u6b63\u6587\u7684\u975e\u4e8c\u8fdb\u5236\u90e8\u5206\uff0c\u4f7f\u7528\u4efb\u4f55\u503c \u5bf9\u4e8e\u5c5e\u6027\u3002<samp>name<\/samp><\/li>\n\n\n\n<li>\u5bf9\u4e8e\u5355\u4e2a\u6587\u6863\uff0c\u5728\u8bf7\u6c42\u7684\u4e8c\u8fdb\u5236\u90e8\u5206 body\uff0c\u8bf7\u4f7f\u7528\u8be5\u5c5e\u6027\u6307\u5b9a \u5bf9\u8c61\u3002\u4f8b\u5982\uff0cblob \u6570\u636e\u5b57\u6bb5\u7684\u540d\u79f0 Document \u5bf9\u8c61\u662f&nbsp;Body\u3002<samp>name<\/samp><\/li>\n\n\n\n<li>\u5bf9\u4e8e\u4f7f\u7528 sObject \u96c6\u5408\u63d2\u5165\u6216\u66f4\u65b0\u7684\u6587\u6863\uff0c \u4f7f\u7528\u5c5e\u6027 \u5728\u8bf7\u6c42\u6b63\u6587\u7684\u6bcf\u4e2a\u4e8c\u8fdb\u5236\u90e8\u5206\u6307\u5b9a\u4e00\u4e2a\u552f\u4e00\u7684 \u8be5\u90e8\u4ef6\u7684\u6807\u8bc6\u7b26\u3002\u5f15\u7528\u8fd9\u4e9b\u6807\u8bc6\u7b26 \u7531\u8bf7\u6c42\u6b63\u6587\u7684\u975e\u4e8c\u8fdb\u5236\u90e8\u5206\u3002<samp>name<\/samp><\/li>\n<\/ul>\n<\/li>\n\n\n\n<li>\u5fc5\u987b\u5305\u542b\u4e8c\u8fdb\u5236\u90e8\u5206\u7684\u5c5e\u6027\uff0c\u8be5\u5c5e\u6027\u8868\u793a\u672c\u5730 \u6587\u4ef6\u3002<samp>filename<\/samp><\/li>\n<\/ul>\n\n\n\n<p class=\"wp-block-paragraph\">Content-Type \u6807\u5934<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>\u5728\u591a\u90e8\u5206\u8bf7\u6c42\u6b63\u6587\u7684\u6bcf\u4e2a\u90e8\u5206\u4e2d\u662f\u5fc5\u9700\u7684\u3002<\/li>\n\n\n\n<li>\u652f\u6301 \u548c \u5185\u5bb9 \u591a\u90e8\u5206\u8bf7\u6c42\u6b63\u6587\u7684\u975e\u4e8c\u8fdb\u5236\u90e8\u5206\u7684\u7c7b\u578b\u3002<samp>application\/json<\/samp><samp>application\/xml<\/samp><\/li>\n\n\n\n<li>\u652f\u6301\u591a\u90e8\u5206\u7684\u4e8c\u8fdb\u5236\u90e8\u5206\u7684\u4efb\u4f55\u5185\u5bb9\u7c7b\u578b \u8bf7\u6c42\u6b63\u6587\u3002<\/li>\n<\/ul>\n\n\n\n<p class=\"wp-block-paragraph\">\u65b0\u884c\u5fc5\u987b\u5728\u6807\u9898\u548c\u6570\u636e\u4e4b\u95f4\u6dfb\u52a0\u4e00\u4e2a\u65b0\u884c\uff0c\u7528\u4e8e \u591a\u90e8\u5206\u8bf7\u6c42\u6b63\u6587\u3002\u6b63\u5982\u60a8\u5728\u793a\u4f8b\u4e2d\u770b\u5230\u7684\uff0c\u4e00\u4e2a\u65b0\u884c \u5c06 \u548c \u6807\u5934\u4e0e JSON \u5206\u5f00 \u6216\u4e8c\u8fdb\u5236\u6570\u636e\u3002<samp>Content-Type<\/samp><samp>Content-Disposition<\/samp><\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li><\/li>\n\n\n\n<li><\/li>\n<\/ul>\n\n\n\n<h4 class=\"wp-block-heading\">\u53e6\u89c1<\/h4>\n\n\n\n<ul class=\"wp-block-list\">\n<li>sObject\u57fa\u672c\u4fe1\u606f<\/li>\n\n\n\n<li>sObject \u884c<\/li>\n\n\n\n<li>sObject \u96c6\u5408<\/li>\n\n\n\n<li>\u83b7\u53d6 Blob \u6570\u636e<\/li>\n<\/ul>\n\n\n\n<h2 class=\"wp-block-heading\">\u83b7\u53d6 Blob \u6570\u636e<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\"><a><\/a>\u4f7f\u7528 sObject Blob Get \u8d44\u6e90\u83b7\u53d6 \u7ed9\u5b9a\u8bb0\u5f55\u3002\u82e5\u8981\u83b7\u53d6 blob \u6570\u636e\uff0c\u5fc5\u987b\u5b58\u5728\u5305\u542b blob \u6570\u636e\u7684\u8bb0\u5f55 Salesforce\u7684\u3002<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">\u53ea\u6709\u67d0\u4e9b\u6807\u51c6\u5bf9\u8c61\u5177\u6709 blob \u5b57\u6bb5\uff0c\u4f8b\u5982 Attachment\u3001ContentNote\u3001 ContentVersion\u3001Document\u3001Folder \u548c Note\u3002<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">\u6ce8\u610f<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">sObject Blob Get \u8d44\u6e90\u4e0e\u590d\u5408 API \u8bf7\u6c42\u4e0d\u517c\u5bb9\uff0c\u56e0\u4e3a\u5b83 \u8fd4\u56de\u4e8c\u8fdb\u5236\u6570\u636e\uff0c\u800c\u4e0d\u662f JSON \u6216 XML \u683c\u5f0f\u7684\u6570\u636e\u3002\u76f8\u53cd\uff0c\u8bf7\u521b\u5efa\u5355\u4e2a sObject Blob \u83b7\u53d6\u68c0\u7d22 blob \u6570\u636e\u7684\u8bf7\u6c42\u3002<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">\u4ee5\u4e0b\u793a\u4f8b\u83b7\u53d6\u5728\u201c\u63d2\u5165\u6216\u66f4\u65b0 Blob\u00a0\u6570\u636e\u201d\u4e2d\u521b\u5efa\u7684\u6587\u6863\u8bb0\u5f55\u7684 blob \u6570\u636e\u3002<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">\u4ece\u6587\u6863\u8bb0\u5f55\u4e2d\u68c0\u7d22 blob \u6570\u636e\u7684\u793a\u4f8b<\/h2>\n\n\n\n<pre class=\"wp-block-code\"><code>curl https:\/\/<em>MyDomainName<\/em>.my.salesforce.com\/services\/data\/v59.0\/sobjects\/Document\/015D0000000N3ZZIA0\/body -H \"Authorization: Bearer <em>token<\/em>\"<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">\u793a\u4f8b\u8bf7\u6c42\u6b63\u6587\u4e0d\u9700\u8981\u793a\u4f8b\u54cd\u5e94\u6b63\u6587\u6587\u6863\u6b63\u6587\u5185\u5bb9\u4ee5\u4e8c\u8fdb\u5236\u5f62\u5f0f\u8fd4\u56de\u3002\u54cd\u5e94\u5185\u5bb9\u7c7b\u578b\u4e0d\u662f JSON \u6216 XML\uff0c\u56e0\u4e3a\u8fd4\u56de\u7684\u6570\u636e\u662f\u4e8c\u8fdb\u5236\u7684\u3002\u60a8\u53ef\u4ee5\u5c06\u8fd4\u56de\u7684\u4e8c\u8fdb\u5236\u6570\u636e\u4fdd\u5b58\u5230\u4e00\u4e2a\u6587\u4ef6\u4e2d \u5b58\u50a8\u548c\u8bbf\u95ee\u5b83\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u672c\u8282\u4e2d\u7684\u793a\u4f8b\u4f7f\u7528 REST API \u8d44\u6e90\u6765\u641c\u7d22\u548c\u67e5\u8be2\u8bb0\u5f55 \u4f7f\u7528 Salesforce \u5bf9\u8c61\u641c\u7d22\u8bed\u8a00 \uff08SOSL\uff09 \u548c Salesforce \u5bf9\u8c61\u67e5\u8be2\u8bed\u8a00 \uff08SOQL\uff09\uff0c\u4ee5\u53ca \u5176\u4ed6\u641c\u7d22 API\u3002\u6709\u5173 SOSL \u548c SOQL \u7684\u8be6\u7ec6\u4fe1\u606f\uff0c\u8bf7\u53c2\u9605\u00a0SOQL \u548c SOSL \u53c2\u8003<\/p>\n","protected":false},"author":1,"featured_media":4387,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[313],"tags":[326],"class_list":["post-4384","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-rest-api-","tag-326"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v21.7 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>\u4f7f\u7528\u641c\u7d22\u548c\u67e5\u8be2 - \u767d\u767d\u968f\u7b14<\/title>\n<meta name=\"description\" content=\"\u672c\u8282\u4e2d\u7684\u793a\u4f8b\u4f7f\u7528 REST API \u8d44\u6e90\u6765\u641c\u7d22\u548c\u67e5\u8be2\u8bb0\u5f55 \u4f7f\u7528 Salesforce \u5bf9\u8c61\u641c\u7d22\u8bed\u8a00 \uff08SOSL\uff09 \u548c Salesforce \u5bf9\u8c61\u67e5\u8be2\u8bed\u8a00 \uff08SOQL\uff09\uff0c\u4ee5\u53ca \u5176\u4ed6\u641c\u7d22 API\u3002\u6709\u5173 SOSL \u548c SOQL \u7684\u8be6\u7ec6\u4fe1\u606f\uff0c\u8bf7\u53c2\u9605\u00a0SOQL \u548c SOSL \u53c2\u8003\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"http:\/\/www.ponybai.com\/?p=4384\" \/>\n<meta property=\"og:locale\" content=\"zh_CN\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"\u4f7f\u7528\u641c\u7d22\u548c\u67e5\u8be2 - \u767d\u767d\u968f\u7b14\" \/>\n<meta property=\"og:description\" content=\"\u672c\u8282\u4e2d\u7684\u793a\u4f8b\u4f7f\u7528 REST API \u8d44\u6e90\u6765\u641c\u7d22\u548c\u67e5\u8be2\u8bb0\u5f55 \u4f7f\u7528 Salesforce \u5bf9\u8c61\u641c\u7d22\u8bed\u8a00 \uff08SOSL\uff09 \u548c Salesforce \u5bf9\u8c61\u67e5\u8be2\u8bed\u8a00 \uff08SOQL\uff09\uff0c\u4ee5\u53ca \u5176\u4ed6\u641c\u7d22 API\u3002\u6709\u5173 SOSL \u548c SOQL \u7684\u8be6\u7ec6\u4fe1\u606f\uff0c\u8bf7\u53c2\u9605\u00a0SOQL \u548c SOSL \u53c2\u8003\" \/>\n<meta property=\"og:url\" content=\"http:\/\/www.ponybai.com\/?p=4384\" \/>\n<meta property=\"og:site_name\" content=\"\u767d\u767d\u968f\u7b14\" \/>\n<meta property=\"article:published_time\" content=\"2024-03-28T12:38:53+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2023-12-18T12:42:08+00:00\" \/>\n<meta property=\"og:image\" content=\"http:\/\/www.ponybai.com\/wp-content\/uploads\/2023\/12\/query.png\" \/>\n\t<meta property=\"og:image:width\" content=\"927\" \/>\n\t<meta property=\"og:image:height\" content=\"573\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/png\" \/>\n<meta name=\"author\" content=\"ponybai\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"\u4f5c\u8005\" \/>\n\t<meta name=\"twitter:data1\" content=\"ponybai\" \/>\n\t<meta name=\"twitter:label2\" content=\"\u9884\u8ba1\u9605\u8bfb\u65f6\u95f4\" \/>\n\t<meta name=\"twitter:data2\" content=\"4 \u5206\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"http:\/\/www.ponybai.com\/?p=4384#article\",\"isPartOf\":{\"@id\":\"http:\/\/www.ponybai.com\/?p=4384\"},\"author\":{\"name\":\"ponybai\",\"@id\":\"http:\/\/www.ponybai.com\/#\/schema\/person\/935c7592c850c65e1e5eba4530dbf883\"},\"headline\":\"\u4f7f\u7528\u641c\u7d22\u548c\u67e5\u8be2\",\"datePublished\":\"2024-03-28T12:38:53+00:00\",\"dateModified\":\"2023-12-18T12:42:08+00:00\",\"mainEntityOfPage\":{\"@id\":\"http:\/\/www.ponybai.com\/?p=4384\"},\"wordCount\":320,\"publisher\":{\"@id\":\"http:\/\/www.ponybai.com\/#\/schema\/person\/935c7592c850c65e1e5eba4530dbf883\"},\"keywords\":[\"\u4f7f\u7528\u641c\u7d22\u548c\u67e5\u8be2\"],\"articleSection\":[\"REST API \u5f00\u53d1\u4eba\u5458\u6307\u5357\"],\"inLanguage\":\"zh-Hans\"},{\"@type\":\"WebPage\",\"@id\":\"http:\/\/www.ponybai.com\/?p=4384\",\"url\":\"http:\/\/www.ponybai.com\/?p=4384\",\"name\":\"\u4f7f\u7528\u641c\u7d22\u548c\u67e5\u8be2 - \u767d\u767d\u968f\u7b14\",\"isPartOf\":{\"@id\":\"http:\/\/www.ponybai.com\/#website\"},\"datePublished\":\"2024-03-28T12:38:53+00:00\",\"dateModified\":\"2023-12-18T12:42:08+00:00\",\"description\":\"\u672c\u8282\u4e2d\u7684\u793a\u4f8b\u4f7f\u7528 REST API \u8d44\u6e90\u6765\u641c\u7d22\u548c\u67e5\u8be2\u8bb0\u5f55 \u4f7f\u7528 Salesforce \u5bf9\u8c61\u641c\u7d22\u8bed\u8a00 \uff08SOSL\uff09 \u548c Salesforce \u5bf9\u8c61\u67e5\u8be2\u8bed\u8a00 \uff08SOQL\uff09\uff0c\u4ee5\u53ca \u5176\u4ed6\u641c\u7d22 API\u3002\u6709\u5173 SOSL \u548c SOQL \u7684\u8be6\u7ec6\u4fe1\u606f\uff0c\u8bf7\u53c2\u9605\u00a0SOQL \u548c SOSL \u53c2\u8003\",\"breadcrumb\":{\"@id\":\"http:\/\/www.ponybai.com\/?p=4384#breadcrumb\"},\"inLanguage\":\"zh-Hans\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"http:\/\/www.ponybai.com\/?p=4384\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"http:\/\/www.ponybai.com\/?p=4384#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"\u9996\u9875\",\"item\":\"http:\/\/www.ponybai.com\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"\u4f7f\u7528\u641c\u7d22\u548c\u67e5\u8be2\"}]},{\"@type\":\"WebSite\",\"@id\":\"http:\/\/www.ponybai.com\/#website\",\"url\":\"http:\/\/www.ponybai.com\/\",\"name\":\"\u767d\u767d\u968f\u7b14\",\"description\":\"Salesforce\u5b98\u65b9\u8bb2\u5e08\",\"publisher\":{\"@id\":\"http:\/\/www.ponybai.com\/#\/schema\/person\/935c7592c850c65e1e5eba4530dbf883\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"http:\/\/www.ponybai.com\/?s={search_term_string}\"},\"query-input\":\"required name=search_term_string\"}],\"inLanguage\":\"zh-Hans\"},{\"@type\":[\"Person\",\"Organization\"],\"@id\":\"http:\/\/www.ponybai.com\/#\/schema\/person\/935c7592c850c65e1e5eba4530dbf883\",\"name\":\"ponybai\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"zh-Hans\",\"@id\":\"http:\/\/www.ponybai.com\/#\/schema\/person\/image\/\",\"url\":\"http:\/\/www.ponybai.com\/wp-content\/uploads\/2025\/03\/cropped-Ihsans-WeChatQR.jpg\",\"contentUrl\":\"http:\/\/www.ponybai.com\/wp-content\/uploads\/2025\/03\/cropped-Ihsans-WeChatQR.jpg\",\"width\":248,\"height\":248,\"caption\":\"ponybai\"},\"logo\":{\"@id\":\"http:\/\/www.ponybai.com\/#\/schema\/person\/image\/\"},\"sameAs\":[\"http:\/\/121.37.188.161\"],\"url\":\"http:\/\/www.ponybai.com\/?author=1\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"\u4f7f\u7528\u641c\u7d22\u548c\u67e5\u8be2 - \u767d\u767d\u968f\u7b14","description":"\u672c\u8282\u4e2d\u7684\u793a\u4f8b\u4f7f\u7528 REST API \u8d44\u6e90\u6765\u641c\u7d22\u548c\u67e5\u8be2\u8bb0\u5f55 \u4f7f\u7528 Salesforce \u5bf9\u8c61\u641c\u7d22\u8bed\u8a00 \uff08SOSL\uff09 \u548c Salesforce \u5bf9\u8c61\u67e5\u8be2\u8bed\u8a00 \uff08SOQL\uff09\uff0c\u4ee5\u53ca \u5176\u4ed6\u641c\u7d22 API\u3002\u6709\u5173 SOSL \u548c SOQL \u7684\u8be6\u7ec6\u4fe1\u606f\uff0c\u8bf7\u53c2\u9605\u00a0SOQL \u548c SOSL \u53c2\u8003","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"http:\/\/www.ponybai.com\/?p=4384","og_locale":"zh_CN","og_type":"article","og_title":"\u4f7f\u7528\u641c\u7d22\u548c\u67e5\u8be2 - \u767d\u767d\u968f\u7b14","og_description":"\u672c\u8282\u4e2d\u7684\u793a\u4f8b\u4f7f\u7528 REST API \u8d44\u6e90\u6765\u641c\u7d22\u548c\u67e5\u8be2\u8bb0\u5f55 \u4f7f\u7528 Salesforce \u5bf9\u8c61\u641c\u7d22\u8bed\u8a00 \uff08SOSL\uff09 \u548c Salesforce \u5bf9\u8c61\u67e5\u8be2\u8bed\u8a00 \uff08SOQL\uff09\uff0c\u4ee5\u53ca \u5176\u4ed6\u641c\u7d22 API\u3002\u6709\u5173 SOSL \u548c SOQL \u7684\u8be6\u7ec6\u4fe1\u606f\uff0c\u8bf7\u53c2\u9605\u00a0SOQL \u548c SOSL \u53c2\u8003","og_url":"http:\/\/www.ponybai.com\/?p=4384","og_site_name":"\u767d\u767d\u968f\u7b14","article_published_time":"2024-03-28T12:38:53+00:00","article_modified_time":"2023-12-18T12:42:08+00:00","og_image":[{"width":927,"height":573,"url":"http:\/\/www.ponybai.com\/wp-content\/uploads\/2023\/12\/query.png","type":"image\/png"}],"author":"ponybai","twitter_card":"summary_large_image","twitter_misc":{"\u4f5c\u8005":"ponybai","\u9884\u8ba1\u9605\u8bfb\u65f6\u95f4":"4 \u5206"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"http:\/\/www.ponybai.com\/?p=4384#article","isPartOf":{"@id":"http:\/\/www.ponybai.com\/?p=4384"},"author":{"name":"ponybai","@id":"http:\/\/www.ponybai.com\/#\/schema\/person\/935c7592c850c65e1e5eba4530dbf883"},"headline":"\u4f7f\u7528\u641c\u7d22\u548c\u67e5\u8be2","datePublished":"2024-03-28T12:38:53+00:00","dateModified":"2023-12-18T12:42:08+00:00","mainEntityOfPage":{"@id":"http:\/\/www.ponybai.com\/?p=4384"},"wordCount":320,"publisher":{"@id":"http:\/\/www.ponybai.com\/#\/schema\/person\/935c7592c850c65e1e5eba4530dbf883"},"keywords":["\u4f7f\u7528\u641c\u7d22\u548c\u67e5\u8be2"],"articleSection":["REST API \u5f00\u53d1\u4eba\u5458\u6307\u5357"],"inLanguage":"zh-Hans"},{"@type":"WebPage","@id":"http:\/\/www.ponybai.com\/?p=4384","url":"http:\/\/www.ponybai.com\/?p=4384","name":"\u4f7f\u7528\u641c\u7d22\u548c\u67e5\u8be2 - \u767d\u767d\u968f\u7b14","isPartOf":{"@id":"http:\/\/www.ponybai.com\/#website"},"datePublished":"2024-03-28T12:38:53+00:00","dateModified":"2023-12-18T12:42:08+00:00","description":"\u672c\u8282\u4e2d\u7684\u793a\u4f8b\u4f7f\u7528 REST API \u8d44\u6e90\u6765\u641c\u7d22\u548c\u67e5\u8be2\u8bb0\u5f55 \u4f7f\u7528 Salesforce \u5bf9\u8c61\u641c\u7d22\u8bed\u8a00 \uff08SOSL\uff09 \u548c Salesforce \u5bf9\u8c61\u67e5\u8be2\u8bed\u8a00 \uff08SOQL\uff09\uff0c\u4ee5\u53ca \u5176\u4ed6\u641c\u7d22 API\u3002\u6709\u5173 SOSL \u548c SOQL \u7684\u8be6\u7ec6\u4fe1\u606f\uff0c\u8bf7\u53c2\u9605\u00a0SOQL \u548c SOSL \u53c2\u8003","breadcrumb":{"@id":"http:\/\/www.ponybai.com\/?p=4384#breadcrumb"},"inLanguage":"zh-Hans","potentialAction":[{"@type":"ReadAction","target":["http:\/\/www.ponybai.com\/?p=4384"]}]},{"@type":"BreadcrumbList","@id":"http:\/\/www.ponybai.com\/?p=4384#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"\u9996\u9875","item":"http:\/\/www.ponybai.com\/"},{"@type":"ListItem","position":2,"name":"\u4f7f\u7528\u641c\u7d22\u548c\u67e5\u8be2"}]},{"@type":"WebSite","@id":"http:\/\/www.ponybai.com\/#website","url":"http:\/\/www.ponybai.com\/","name":"\u767d\u767d\u968f\u7b14","description":"Salesforce\u5b98\u65b9\u8bb2\u5e08","publisher":{"@id":"http:\/\/www.ponybai.com\/#\/schema\/person\/935c7592c850c65e1e5eba4530dbf883"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"http:\/\/www.ponybai.com\/?s={search_term_string}"},"query-input":"required name=search_term_string"}],"inLanguage":"zh-Hans"},{"@type":["Person","Organization"],"@id":"http:\/\/www.ponybai.com\/#\/schema\/person\/935c7592c850c65e1e5eba4530dbf883","name":"ponybai","image":{"@type":"ImageObject","inLanguage":"zh-Hans","@id":"http:\/\/www.ponybai.com\/#\/schema\/person\/image\/","url":"http:\/\/www.ponybai.com\/wp-content\/uploads\/2025\/03\/cropped-Ihsans-WeChatQR.jpg","contentUrl":"http:\/\/www.ponybai.com\/wp-content\/uploads\/2025\/03\/cropped-Ihsans-WeChatQR.jpg","width":248,"height":248,"caption":"ponybai"},"logo":{"@id":"http:\/\/www.ponybai.com\/#\/schema\/person\/image\/"},"sameAs":["http:\/\/121.37.188.161"],"url":"http:\/\/www.ponybai.com\/?author=1"}]}},"_links":{"self":[{"href":"http:\/\/www.ponybai.com\/index.php?rest_route=\/wp\/v2\/posts\/4384","targetHints":{"allow":["GET"]}}],"collection":[{"href":"http:\/\/www.ponybai.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/www.ponybai.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/www.ponybai.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/www.ponybai.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=4384"}],"version-history":[{"count":3,"href":"http:\/\/www.ponybai.com\/index.php?rest_route=\/wp\/v2\/posts\/4384\/revisions"}],"predecessor-version":[{"id":4388,"href":"http:\/\/www.ponybai.com\/index.php?rest_route=\/wp\/v2\/posts\/4384\/revisions\/4388"}],"wp:featuredmedia":[{"embeddable":true,"href":"http:\/\/www.ponybai.com\/index.php?rest_route=\/wp\/v2\/media\/4387"}],"wp:attachment":[{"href":"http:\/\/www.ponybai.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=4384"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/www.ponybai.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=4384"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/www.ponybai.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=4384"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}