| 12345678910111213141516171819202122232425262728293031323334353637383940 |
- # Query Parse _User class to find a real user ID for testing
- $headers = @{ "X-Parse-Application-Id" = "ncloudmaster" }
- # List a few users (limit 5)
- Write-Host "=== Query _User (limit 5) ===" -ForegroundColor Cyan
- try {
- $encoded = [System.Uri]::EscapeDataString('{"_created_at":{"$gt":{"__type":"Date","iso":"2025-01-01T00:00:00.000Z"}}}')
- $url = "https://server.fmode.cn/parse/classes/_User?limit=5&order=-createdAt&keys=objectId,username,email,createdAt&where=$encoded"
- $r = Invoke-RestMethod -Uri $url -Method GET -Headers $headers -TimeoutSec 15
- Write-Host "Users found:" -ForegroundColor Green
- $r.results | ForEach-Object {
- Write-Host " objectId=$($_.objectId) username=$($_.username) created=$($_.createdAt)"
- }
- } catch {
- Write-Host "Error: $($_.Exception.Message)" -ForegroundColor Red
- # Try without where clause
- Write-Host "Trying without filter..." -ForegroundColor Yellow
- try {
- $r2 = Invoke-RestMethod -Uri "https://server.fmode.cn/parse/classes/_User?limit=3&order=-createdAt&keys=objectId,username,createdAt" -Method GET -Headers $headers -TimeoutSec 15
- $r2.results | ForEach-Object {
- Write-Host " objectId=$($_.objectId) username=$($_.username) created=$($_.createdAt)"
- }
- } catch {
- Write-Host "Also failed: $($_.Exception.Message)" -ForegroundColor Red
- }
- }
- Write-Host ""
- # Also check APIGAuth for any existing records linked to Vo3ROWEvDy
- Write-Host "=== Query APIGAuth linked to APIG Vo3ROWEvDy ===" -ForegroundColor Cyan
- try {
- $where2 = [System.Uri]::EscapeDataString('{"apig":{"__type":"Pointer","className":"APIG","objectId":"Vo3ROWEvDy"}}')
- $url2 = "https://server.fmode.cn/parse/classes/APIGAuth?limit=5&where=$where2"
- $r3 = Invoke-RestMethod -Uri $url2 -Method GET -Headers $headers -TimeoutSec 15
- Write-Host "APIGAuth records:" -ForegroundColor Green
- $r3 | ConvertTo-Json -Depth 5
- } catch {
- Write-Host "Error: $($_.Exception.Message)" -ForegroundColor Red
- }
|