@@ -184,30 +184,32 @@ jobs:
184184 - name : Verify publication
185185 env :
186186 NAME : ${{ fromJSON(steps.server.outputs.json).name }}
187+ VERSION : ${{ fromJSON(steps.server.outputs.json).version }}
187188 run : |
188- echo "⏳ Waiting for registry propagation... "
189- sleep 30
189+ echo "✅ Publication command completed successfully "
190+ echo "📋 Published server: $NAME version $VERSION"
190191
191- # Try to fetch the specific server by ID
192- echo "🔍 Verifying server publication: $NAME"
192+ echo "🔍 Verifying publication in registry..."
193193
194- # Use the specific server endpoint as recommended by MCP Registry docs
195- response=$(curl -s -w "%{http_code}" "https://registry.modelcontextprotocol.io/v0/servers/$NAME" -o server_response.json)
194+ # Use search parameter to find our server (includes all versions)
195+ server_name_only=$(echo "$NAME" | sed 's/.*\///')
196+ curl -s "https://registry.modelcontextprotocol.io/v0/servers?search=$server_name_only" > search_results.json
196197
197- if [ "$response" = "200" ]; then
198- echo "✅ Server $NAME successfully published to MCP Registry"
198+ # Check if our specific version exists
199+ version_found=$(jq -r --arg name "$NAME" --arg version "$VERSION" '.servers[] | select(.name == $name and .version == $version) | .version' search_results.json)
200+
201+ if [ -n "$version_found" ]; then
202+ echo "✅ Server $NAME version $VERSION is published in MCP Registry!"
199203 echo "📋 Server details:"
200- cat server_response.json | jq '.name, .description, .version'
201- elif [ "$response" = "404" ]; then
202- echo "❌ Server $NAME not found in registry"
203- echo "🔍 This could be due to:"
204- echo " - Registry propagation delay (try again in a few minutes)"
205- echo " - Publication failed silently"
206- echo " - Incorrect server name format"
207- exit 1
204+ jq -r --arg name "$NAME" --arg version "$VERSION" '.servers[] | select(.name == $name and .version == $version) | {name, version, description, is_latest: ._meta."io.modelcontextprotocol.registry/official".is_latest}' search_results.json
205+
206+ # Show all versions of this server
207+ echo ""
208+ echo "� All published versions:"
209+ jq -r --arg name "$NAME" '.servers[] | select(.name == $name) | " - v" + .version + " (latest: " + (._meta."io.modelcontextprotocol.registry/official".is_latest | tostring) + ")"' search_results.json | sort -V
208210 else
209- echo "⚠️ Unexpected response code: $response "
210- echo "📄 Response body :"
211- cat server_response. json
211+ echo "❌ Server $NAME version $VERSION not found in registry "
212+ echo "🔍 Available versions for this server :"
213+ jq -r --arg name "$NAME" '.servers[] | select(.name == $name) | " - v" + .version' search_results. json | sort -V
212214 exit 1
213215 fi
0 commit comments