{"surface":{"slug":"web-sdk-methods","title":"mGIS methods for Web Maps JS","stateModel":"browser-runtime","readiness":"entitlement-required","summary":"List, render, inspect, style, bound, and visualize entitled tenant or catalog datasets through the documented v1.0 browser module.","durableIdentity":"Dataset/workspace identity, style revision, view revision, and feature identity copied into application state","credentialBoundary":"The documented methods accept access_token in browser JavaScript. This planner emits only YOUR_MAPPLS_MGIS_ACCESS_TOKEN and never accepts a credential value.","sourceLabels":["Official Web JS mGIS Methods v1.0"],"sourceUrls":["https://developer.mappls.com/documentation/sdk/Web/Web%20JS/docs/V3.0/mGIS_Methods/"],"evidenceBoundary":"The official method guide documents twelve discovery, visualization, info, style, bounds, centroid, catalog, and raster calls. Two examples contain naming drift and remain selection-required until confirmed."},"method":{"slug":"feature-centroid","title":"Read a feature centroid","callName":"getFeatureCentroid","purpose":"Fetch the centroid of one tenant or catalog feature.","requiredFields":["datasetName","featureID","access_token"],"optionalFields":["datastorename"],"evidenceStatus":"documented","evidenceBoundary":"The exact constructor, datasetName, featureID, and optional catalog datastore are documented."},"readiness":"source-ready-after-entitlement","samples":[{"language":"html","label":"SDK loader","code":"<script src=\"https://embed.mappls.com/mgis_sdk/?v=1.0\"></script>\n<div id=\"map\" aria-label=\"mGIS dataset map\"></div>"},{"language":"javascript","label":"Read a feature centroid","code":"new mappls.getFeatureCentroid({\n  datasetName: \"approved_dataset\",\n  featureID: \"APPROVED_FEATURE_ID\",\n  access_token: \"YOUR_MAPPLS_MGIS_ACCESS_TOKEN\",\n}, (result) => {\n  // Validate and copy only the fields your application owns.\n  acceptMgisCandidate(result);\n});"},{"language":"typescript","label":"Application boundary","code":"type MgisCandidate = {\n  schemaVersion: 1;\n  workspaceId: string;\n  datasetId: string;\n  sourceRevision: string;\n};\n\nfunction acceptMgisCandidate(value: unknown) {\n  const candidate = parseMgisCandidate(value); // application-owned allow-list\n  repository.commitCandidate(candidate, { expectedVersion, idempotencyKey });\n}"}],"lifecycle":[{"state":"selected","owner":"Product and workspace owner","proof":"Surface, account/tenant, region, entitlement, data class, and source contract are approved."},{"state":"configuring","owner":"Application adapter","proof":"One bounded configuration references stable workspace/dataset/workview identity and no server secret enters the browser."},{"state":"active","owner":"Host lifecycle","proof":"One instance or job owns listeners, requests, cancellation, retries, and observable health."},{"state":"candidate","owner":"Application domain","proof":"Provider output is schema-checked and normalized; it has not silently replaced durable state."},{"state":"committed","owner":"Application repository","proof":"A versioned record binds actor, source, provider identity, input revision, and event."},{"state":"retired / disposed","owner":"Application and workspace administrator","proof":"Runtime resources are released; durable datasets, lineage, permissions, and audit follow policy."}],"stateOwnership":["Dataset/workspace identity, style revision, view revision, and feature identity copied into application state","The documented methods accept access_token in browser JavaScript. This planner emits only YOUR_MAPPLS_MGIS_ACCESS_TOKEN and never accepts a credential value.","Provider UI/runtime is never the application database; persist normalized identities, versions, receipts, and lineage outside the browser instance.","A load, callback, tile, legend, or image proves only that observable event. Publication, analysis completion, sharing, and export require their own durable evidence."],"releaseTests":["Issued tenant, region, dataset, method, and credential class","Allowed and denied browser origins plus CSP","Slow, offline, quota, expired entitlement, and revoked access","Duplicate initialization, late callback, unmount, and browser back/forward cache","Dataset/style/workview version drift","Accessibility and non-map representation","Idempotency, expected version, unknown outcome, and reconciliation","Privacy, export, share, retention, audit, and deletion policy"],"warnings":["The official method guide documents twelve discovery, visualization, info, style, bounds, centroid, catalog, and raster calls. Two examples contain naming drift and remain selection-required until confirmed.","The exact constructor, datasetName, featureID, and optional catalog datastore are documented.","Examples are configuration/adapter contracts with placeholders. They do not claim a live entitlement or unlisted endpoint."],"evidence":[{"label":"Official Web JS mGIS Methods v1.0","url":"https://developer.mappls.com/documentation/sdk/Web/Web%20JS/docs/V3.0/mGIS_Methods/"}],"websiteUrl":"/tools/mgis?surface=web-sdk-methods&method=feature-centroid"}