hosting

GET /v1/sites/{siteId}/repo/sync

Two-way sync settings, state and recent runs for a site.

සියලුම hosting අන්ත ලක්ෂ්‍ය

සත්‍යාපනය

බෙරර් ටෝකනයක් ලෙස API යතුරක් යවන්න. යතුරෙහි sites.view අවසරය තිබිය යුතුය; එය නොමැති යතුරක් 404 ලෙස නොව 403 ලෙස ප්‍රතික්ෂේප කෙරේ.

මෙම අවසාන ලක්ෂ්‍යය සඳහා සංවිධාන හැඳුනුම්පතක් (organisation id) අවශ්‍ය නොවේ. ඔබගේ යතුර මඟින් එය අයත් වන සංවිධානය දැනටමත් හඳුනා ගන්නා අතර, ප්‍රතිචාරය ඒ වෙත සීමා වේ.

උත්සාහ කරන්න

<අගයන්> සමඟ කෝණික වරහන් තුළ ඇති ඕනෑම දෙයක් සහ ඔබේ උපකරණ පුවරුවෙන් ලබාගත් යතුරක් සමඟ key ස්ථාන දායකය ප්‍රතිස්ථාපනය කරන්න.

curl -X GET https://api.zinndigital.com/v1/sites/{siteId}/repo/sync \
  -H "Authorization: Bearer zdk_live_…"

පද්ධතියට පිවිස සිටිනවාද? ඔබගේ උපකරණ පුවරුවේ ඇති API කොන්සෝලය මඟින් ඔබේ සැබෑ ආයතනික හැඳුනුම්පත සහ ඔබේම යතුර පුරවා, සජීවී API වෙත ඉල්ලීම ක්‍රියාත්මක කරන බැවින් ඔබට සැබෑ ප්‍රතිචාරය දැකගත හැක. මෙම අග්‍රලක්ෂ්‍යය API කොන්සෝලය තුළ විවෘත කරන්න

විස්තර

Whether this site's own files are committed back to its repository, where the sync currently stands, and the last runs. `available` is false when the customer has not connected their own account — two-way sync is free but only ever writes to a repository on an account the customer owns, so a pooled account of ours is never enough. `state` of `conflict` or `adopt` means the sync is HELD, waiting for the customer to choose; it is not an error and it will not clear itself. Requires `sites.view`.

පරාමිතීන්

නමවර්ගයඅත්‍යවශ්‍යයිඑය කුමක්ද
siteId (path)Uuidඔව්Site ID (UUIDv7).

පsspil

නමවර්ගයඅත්‍යවශ්‍යයිඑය කුමක්ද
site_idstringඔව්
enabledbooleanඔව්Whether the customer has switched two-way sync on.
availablebooleanඔව්Whether it is permitted at all — true only once the customer has connected their OWN git account. False here makes `enabled` irrelevant; the engine will not sync either way.
unavailable_reasonstringනැතA sentence the customer reads when `available` is false. Null when it is available.
subdirstringනැතWhich directory of the site syncs. Empty means the whole document root.
statestring<idle, synced, conflict, adopt, error>ඔව්`conflict` and `adopt` are HELD, not failed — the sync stopped on purpose and is waiting for the customer to choose a side.
branchstringනැත
repositorystringනැත`owner/repo`, or null when no repository is connected.
conflict_commitstringනැතThe commit in the repository that we have not seen — the one the customer needs to look at before choosing. Null unless held.
last_sync_atstringනැත
last_sync_notestringනැත
runsSiteRepoSyncRun[]ඔව්The most recent runs, newest first. Includes the no-ops.

මෙම අවසාන ලක්ෂ්‍යය ආපසු ලබා දිය හැකි දෝෂ

401 · 403 · 404 · 429