Repository navigation
FAQ
Answers to common questions about @selldone/sdk-community, including the setup errors developers run into most
often.
Yes. window.$community.getCommunityID() without a shop returns 1, the main Selldone community. Use it to test
reading info and searching posts.
The community ID is empty. This usually means getCommunityID(shop) was called with a shop that has no community
yet (shop.community is missing), or with a shop object that was loaded without its community. Create the community
first (in the Selldone dashboard, or with POST /shops/{shop_id}/community via window.CAPI.POST_COMMUNITY_CREATE),
or reload the shop with its community.
The selldone-capi meta tag is missing, so window.CAPI has no base URL. Add
<meta name="selldone-capi" content="https://capi.selldone.com"> before calling CapiCommunity.Setup().
Write actions need a signed-in user. The Community SDK does not handle authentication; it uses whatever
Authorization header is set on window.axios. In a storefront, set up the
Storefront SDK before the Community SDK so the customer's session
is used. Otherwise set the header yourself.
The package entry exports only CapiCommunity. Import the helper by path:
import { CommunityURLs } from "@selldone/sdk-community/url/CommunityURLs";The link helpers need the main service URL. Add <meta name="service-url" content="https://selldone.com">, and
selldone-iframe if you build embed links. See Getting Started.
Yes. Components (@selldone/components-vue) contains the full community
UI used by the Selldone Storefront: layout, home, feed, category and topic pages, post editor, comments, polls,
reports, moderation and statistics. The Storefront mounts it under
/community.
Not directly. It reads its configuration from <meta> tags and registers globals on window. On a server, call the
community routes listed in Community API URL Builders with any HTTP client.
searchPosts(community_id, offset, limit, search) returns { posts, more }. Increase offset by limit while
more is true. See JavaScript SDK.
Community API limits are not documented in this repository. Debounce search inputs, cache results with
.cache() and .optimize(), and handle 429 Too Many Requests with a back-off and retry.