#asknostr Ok have i got my NIP-05 right?
How can i verify that it works?
#asknostr Ok have i got my NIP-05 right?
How can i verify that it works?
No, it's didn't work, because your `nostr.json` content is https://prickigakatten.se/.well-known/nostr.json
```json
{
"names": {
"Speedy Gonzales": "f83e8392a4cddf17b56287bb5805b4adf5ce2c66bb9e4e7c8baf9770e519e9a5"
}
}
```
The nip-5 says:
> NIP-05 assumes the
So you shouldn't use a space, you can change it to
```json
{
"names": {
"speedy": "f83e8392a4cddf17b56287bb5805b4adf5ce2c66bb9e4e7c8baf9770e519e9a5"
}
}
```
And it will works. Also consider to add your recommended relays.
Excuse a noob question but where can i find my recommended relays?
The recommended relays it's a relyas you recommend the clients to search for you in it, your profile, note, ext, any event belong to you.
So, you have to choice them, you can find relays at https://legacy.nostr.watch/relays/find but make sure they are writable.
And add the same relays to your client, your client may update your relay list (NIP-65)
it's getting a CORS error
Please explain to a nostr-noob
your server that hosts the NIP-05 needs to include this header in the response:
access-control-allow-origin: *
Thanks, but I have no idea what this means. 🫤
how are you hosting your NIP-05?
On my web-hotel
can you control the HTTP response headers?
I cat find any settings for that.
is this some kind of free hosting site?
No I pay for hosting https://websupport.se/
you could switch to Vercel. it's free and no CORS error
i will check with my web host support.
does it support PHP?
Yes i think so
can you try this?
header("Access-Control-Allow-Origin: *");
?>
Where shall i put it?
couldn't tell you, I don't work with PHP myself
thanks for the satoshis 🫂
No thank you! for your time and effort 😃
I got a responce from my web-host
They recommended that i shall put
Header set Access-Control-Allow-Origin "*"
in .htaccess in the root folder of my web page.
I have now done that but I cant verify if it is working.
But im not shure if i just shold pu this text in the file if i need to format it to be readable correctly.
Nevermind, i got it to work ;) Wooohooo..
Thanks for all your help!
I had placed the .htaccess file in the worong place 😉
I still see the CORS error
I guess something is wrong with noStrudel, because I see your json is fetching properly and has the correct Access-Control-Allow-Origin header
Thats funny, This morning I got the check mark on my profile. And everything looked good. I havent changed anything since and now its gone? "poof"
I don't understand it! according to this you are good: https://cors-test.codehappy.dev/?url=https%3A%2F%2Fprickigakatten.se%2F.well-known%2Fnostr.json%3Fname%3Dspeedy&origin=https%3A%2F%2Fcors-test.codehappy.dev%2F&method=get
but some clients still display the error
Yes very funny. I got the check mark this this morning and now its gone. I haven´t changed anything since then. Maybe it will come back again 😄
header("Access-Control-Allow-Origin: *")
echo file_get_contents("nip05.json")