Add free-text api_instructions field to Sites
For custom sites we'll post to via their own API — there's no wired-in publisher for these, so this is where the site owner documents how to actually post there (auth, endpoints, payload shape). Shown in the UI for non-WordPress sites, exposed via the JSON API, and pointed to from AI_API.md's "any other network/CMS" fallback section so an agent checks it before improvising. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This commit is contained in:
@@ -34,6 +34,8 @@
|
||||
{{ $revealedId === $site->id ? 'Hide' : 'Show' }}
|
||||
</button>
|
||||
</div>
|
||||
@elseif ($site->api_instructions)
|
||||
<div class="text-xs text-gray-500" title="{{ $site->api_instructions }}">Has API instructions</div>
|
||||
@endif
|
||||
</td>
|
||||
<td class="p-3 text-right space-x-2">
|
||||
@@ -89,6 +91,13 @@
|
||||
<input type="text" wire:model="wpAppPassword" class="w-full border rounded p-2">
|
||||
@error('wpAppPassword') <span class="text-red-600 text-sm">{{ $message }}</span> @enderror
|
||||
</div>
|
||||
@else
|
||||
<div>
|
||||
<label class="block text-sm font-medium">API Instructions (optional)</label>
|
||||
<p class="text-xs text-gray-500 mb-1">Notes for posting here via this site's own API — auth method, endpoints, payload shape, etc. Read by whoever (agent or you) ends up publishing to it.</p>
|
||||
<textarea wire:model="apiInstructions" rows="4" class="w-full border rounded p-2"></textarea>
|
||||
@error('apiInstructions') <span class="text-red-600 text-sm">{{ $message }}</span> @enderror
|
||||
</div>
|
||||
@endif
|
||||
|
||||
<div class="flex justify-end gap-2">
|
||||
|
||||
Reference in New Issue
Block a user