platform-agentexchange-partner-offers-configure
Enable or disable the org preference that controls whether a Salesforce org can receive partner offers from the Transactable Marketplace. Use this s…
它会碰到什么
这一栏是扫描器报的事实,不是结论。命中多不等于有毒(安全工具、规则库、示例脚本本来就会包含危险写法),命中少也不等于干净。它和你手上的凭据、文件、网络有什么关系,需要你自己看。
技能内容
Enabling Transactable Marketplace Receive Partner Offers Org Preference
This skill configures the enableTransactableMarketplaceReceivePartnerOffers org preference via the TransactableMarketplacePrivateOfferSettings Metadata API type, which controls whether a Salesforce org is eligible to receive partner offers through the Transactable Marketplace. It is required for subscriber orgs that participate in the TM partner offer flow.
Scope
- In scope: Reading the current value of the pref, enabling or disabling it via Metadata API (
TransactableMarketplacePrivateOfferSettings), and verifying the change took effect. - Out of scope: Creating or managing partner offer records, configuring marketplace listings, or any Apex/trigger changes related to offer processing.
Required Inputs
- Target org alias or username: The org where the pref should be set. Ask if not provided.
- Desired state:
true(enable) orfalse(disable). Default:true.
Workflow
Phase 1 — Check current state
- Query the current preference value by running:
sf data query -q "SELECT Preference, Value FROM OrgPreference WHERE Preference = 'TransactableMarketplaceReceivePartnerOffers'" --target-org <alias> --use-tooling-api
If the record exists and Value = true, the pref is already enabled — confirm with the user before proceeding.
If the query returns no rows, the pref is not yet set (defaults to false).
- Resolve the org's package directory to determine where to write metadata. Run this and use its output as
<packageDir>:
jq -r '.packageDirectories[0].path // "force-app/main/default"' sfdx-project.json
Phase 2 — Apply the preference
- Write the TransactableMarketplacePrivateOfferSettings metadata file — load
assets/org-pref-template.mdfor the exact XML structure, then write the file at:
<packageDir>/settings/TransactableMarketplacePrivateOffer.settings
Set <enableTransactableMarketplaceReceivePartnerOffers>true</enableTransactableMarketplaceReceivePartnerOffers> (or false if disabling).
- Deploy the metadata to the target org. Before running the deploy, confirm with the user:
- [ ] Confirmed the target org alias with the user (deploying to the wrong org is not easily reversible)
- [ ] Confirmed the desired state (
true/false) matches the user's intent
sf project deploy start --metadata TransactableMarketplacePrivateOfferSettings --target-org <alias>
Phase 3 — Verify
- Confirm the change by re-running the Tooling API query from step 1 and verifying the
Valuecolumn matches the desired state.
- Report to the user — see Output Expectations below.
Rules / Constraints
| Rule | Rationale |
|------|-----------|
| Always query the current value before writing metadata | Avoids unnecessary deploys and detects conflicting changes |
| Use TransactableMarketplacePrivateOfferSettings as the metadata type | This is the concrete type registered in the platform for this pref, not the generic OrgPreferenceSettings |
| The settings file must be named TransactableMarketplacePrivateOffer.settings | Metadata API requires the filename to match the settings node name |
| Do not hardcode force-app/main/default/ | Always read sfdx-project.json for the actual package directory |
| Never deploy without confirming the org alias with the user | Deploying to the wrong org is not easily reversible |
Gotchas
| Issue | Resolution |
|-------|------------|
| Tooling API query returns no rows | Pref is unset (defaults to false). Safe to create a new settings file. |
| Deploy fails with INVALID_TYPE | The metadata type name is TransactableMarketplacePrivateOfferSettings — check the --metadata flag value. |
| Deploy succeeds but value doesn't change | Another settings file in the project may be overriding this one. Search for other TransactableMarketplacePrivateOffer.settings files in the project. |
| INSUFFICIENT_ACCESS_OR_READONLY on deploy | User running the deploy must have the "Modify All Data" or org preference admin permission in the target org. |
| Pref not visible in UI | enableTransactableMarketplaceReceivePartnerOffers is not surfaced in Setup UI — the Tooling API query is the only way to verify it. |
| Available from API version 67.0+ only | The type is available from API v67.0 — deploying against an older API version will fail. |
Output Expectations
After completing all phases, report:
Org: <alias>
Preference: enableTransactableMarketplaceReceivePartnerOffers
Previous value: <true|false|unset>
New value: <true|false>
File written: <packageDir>/settings/TransactableMarketplacePrivateOffer.settings
Deploy status: Success
Reference File Index
| File | When to read |
|------|-------------|
| assets/org-pref-template.md | Phase 2, step 3 — use as the exact XML structure for the settings file |
| examples/org-preference-settings.xml | To verify the generated file matches expected format |
想直接用这个技能?
本站把开放许可(MIT / Apache 等)的技能按仓库打包整理到网盘,点一下转存到你自己的网盘,不用一个个从 GitHub 拉。许可未声明的技能只给原始仓库链接,不打包。
它属于哪个仓库
plugins/builder/dx-isv-partner/skills/platform-agentexchange-partner-offers-configure/SKILL.md同一个仓库里的其他技能
- commerce-b2b-open-code-components-integrate
- commerce-b2b-open-code-components-replace
- dx-devops-conflict-resolve
- dx-devops-pipeline-manage
- dx-devops-test-failures-analyze
- dx-devops-test-pipeline-configure
- dx-devops-test-suite-assignments-configure
- dx-devops-test-suite-run
- dx-devops-work-item-manage
- dx-app-analytics-query
- automation-sandbox-post-copy-config-generate
- automation-sandbox-post-copy-configure
同名技能的其他版本
有 2 个不同仓库或目录里都有叫 platform-agentexchange-partner-offers-configure 的技能。它们内容并不相同,别混用:
- forcedotcom/sf-skills — Enable or disable the org preference that controls whether a Salesforce org can receive pa