{"openapi":"3.1.0","info":{"title":"Norgesdomene API","version":"1.3.0","description":"REST-API for domenesøk, domener, DNS, navnetjenere og bestilling mot forhåndssaldo. Dokumentasjon: https://norgesdomene.no/api-docs. Vilkår for bestilling: https://norgesdomene.no/api-vilkar. Nye felt kan dukke opp i svar uten ny hovedversjon; ignorer felt du ikke kjenner.","x-changelog":[{"version":"1.3.0","date":"2026-10-14","changes":["dryRun=true på POST /domains, /domains/transfers og /domains/:id/renew. Kjører kontrollene uten å bestille.","Maskinlesbar spesifikasjon på /api/v1/openapi.json."]},{"version":"1.2.0","date":"2026-10-14","changes":["PATCH /domains/:id for å slå automatisk fornyelse av og på.","POST /domains/:id/declaration-link lager en ny lenke til egenerklæringen (krever domains:order).","GET /domains/:id viser declaration og declarationUrl. GET /domains viser autoRenew.","Nye webhooks: domain.declaration.signed, domain.registered, domain.registration.failed og domain.renewed."]},{"version":"1.1.0","date":"2026-10-14","changes":["Bestilling krever scopet domains:order. Nøkler som hadde bestillingsrett fra før, fikk det automatisk.","Nye feilkoder: ordering_blocked (403) og order_limit_reached (429).","GET /account krever bare domains:read og viser ordering.status, dailyOrderLimit og keyCanOrder."]}]},"servers":[{"url":"https://norgesdomene.no/api/v1"}],"tags":[{"name":"Domener"},{"name":"Bestilling","description":"Krever domains:order og aktivert API-bestilling. Standard døgngrense: 50 bestillinger."},{"name":"DNS"},{"name":"Konto"}],"paths":{"/domains/check":{"get":{"summary":"Sjekk om et .no-domene er ledig, med pris","tags":["Domener"],"x-required-scope":"domains:read","security":[{"bearerAuth":[]}],"parameters":[{"name":"domain","in":"query","required":true,"schema":{"type":"string"},"example":"kundensbedrift.no"}],"responses":{"200":{"description":"Svar fra registeret","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AvailabilityResult"}}}},"400":{"description":"invalid_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"unauthorized: ugyldig eller manglende nøkkel","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"forbidden_scope, api_disabled eller ordering_blocked","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"rate_limited (120 per minutt per nøkkel) eller order_limit_reached","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"availability_unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/domains":{"get":{"summary":"List domener på kontoen (maks 200)","tags":["Domener"],"x-required-scope":"domains:read","security":[{"bearerAuth":[]}],"responses":{"200":{"description":"Domener","content":{"application/json":{"schema":{"type":"object","required":["domains"],"properties":{"domains":{"type":"array","items":{"$ref":"#/components/schemas/DomainSummary"}}}}}}},"401":{"description":"unauthorized: ugyldig eller manglende nøkkel","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"forbidden_scope, api_disabled eller ordering_blocked","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"rate_limited (120 per minutt per nøkkel) eller order_limit_reached","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"post":{"summary":"Registrer et .no-domene mot saldo","description":"Svarer 202 med declarationUrl. Domenet registreres først når innehaveren har signert egenerklæringen. Følg status med webhooks eller GET /domains/{id}.","tags":["Bestilling"],"x-required-scope":"domains:order","security":[{"bearerAuth":[]}],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"description":"Påkrevd for ekte bestillinger, ikke for dryRun. Unik per bestilling. Send samme nøkkel og samme innhold ved retry for å få samme ordre uten ny belastning.","schema":{"type":"string","maxLength":255}},{"name":"dryRun","in":"query","required":false,"description":"true eller 1: kjør pris-, ledighets-, kvote- og saldokontrollene uten å bestille. Svarer 200 med OrderPreview, eller med samme feil som en ekte bestilling.","schema":{"type":"boolean"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RegisterRequest"},"example":{"domain":"kundensbedrift.no","registrant":{"type":"organisasjon","name":"Kundens Bedrift AS","orgNumber":"123456789","email":"post@kundensbedrift.no","country":"NO"}}}}},"responses":{"200":{"description":"dryRun: kontrollene passerte","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrderPreview"}}}},"202":{"description":"Bestilling mottatt","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PlaceResult"}}}},"400":{"description":"invalid_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"unauthorized: ugyldig eller manglende nøkkel","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"insufficient_balance","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"forbidden_scope, api_disabled eller ordering_blocked","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"domain_taken eller conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"invalid_contact","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"rate_limited (120 per minutt per nøkkel) eller order_limit_reached","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"502":{"description":"provisioning_failed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"availability_unavailable, reconciliation_required eller norid_busy","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/domains/transfers":{"post":{"summary":"Flytt et .no-domene hit","description":"Navnetjenerne beholdes. Svarer 202; flyttingen fullføres i bakgrunnen og varsles med domain.transfer.completed eller domain.transfer.failed.","tags":["Bestilling"],"x-required-scope":"domains:order","security":[{"bearerAuth":[]}],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"description":"Påkrevd for ekte bestillinger, ikke for dryRun. Unik per bestilling. Send samme nøkkel og samme innhold ved retry for å få samme ordre uten ny belastning.","schema":{"type":"string","maxLength":255}},{"name":"dryRun","in":"query","required":false,"description":"true eller 1: kjør pris-, ledighets-, kvote- og saldokontrollene uten å bestille. Svarer 200 med OrderPreview, eller med samme feil som en ekte bestilling.","schema":{"type":"boolean"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TransferRequest"},"example":{"domain":"kundensbedrift.no","authCode":"abc123XYZ"}}}},"responses":{"200":{"description":"dryRun: kontrollene passerte","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrderPreview"}}}},"202":{"description":"Flytting bestilt","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PlaceResult"}}}},"400":{"description":"invalid_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"unauthorized: ugyldig eller manglende nøkkel","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"insufficient_balance","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"forbidden_scope, api_disabled eller ordering_blocked","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"domain_taken eller conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"rate_limited (120 per minutt per nøkkel) eller order_limit_reached","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"reconciliation_required eller norid_busy","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/domains/{id}":{"get":{"summary":"Hent ett domene, med status for egenerklæringen","tags":["Domener"],"x-required-scope":"domains:read","security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"description":"Domene-ID","schema":{"type":"string","format":"uuid"}}],"responses":{"200":{"description":"Domenet","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DomainDetail"}}}},"401":{"description":"unauthorized: ugyldig eller manglende nøkkel","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"forbidden_scope, api_disabled eller ordering_blocked","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"not_found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"rate_limited (120 per minutt per nøkkel) eller order_limit_reached","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"patch":{"summary":"Slå automatisk fornyelse av eller på","description":"Samme regler og fakturaeffekt som i kundeportalen. Maks 8 endringer per domene per time.","tags":["Domener"],"x-required-scope":"domains:write","security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"description":"Domene-ID","schema":{"type":"string","format":"uuid"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateDomainRequest"},"example":{"autoRenew":false}}}},"responses":{"200":{"description":"Oppdatert","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateDomainResult"}}}},"400":{"description":"invalid_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"unauthorized: ugyldig eller manglende nøkkel","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"forbidden_scope, api_disabled eller ordering_blocked","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"not_found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"rate_limited (120 per minutt per nøkkel) eller order_limit_reached","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"502":{"description":"provisioning_failed: flagget kan være lagret; les domenet på nytt","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/domains/{id}/renew":{"post":{"summary":"Forny et domene mot saldo","tags":["Bestilling"],"x-required-scope":"domains:order","security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"description":"Domene-ID","schema":{"type":"string","format":"uuid"}},{"name":"Idempotency-Key","in":"header","required":false,"description":"Påkrevd for ekte bestillinger, ikke for dryRun. Unik per bestilling. Send samme nøkkel og samme innhold ved retry for å få samme ordre uten ny belastning.","schema":{"type":"string","maxLength":255}},{"name":"dryRun","in":"query","required":false,"description":"true eller 1: kjør pris-, ledighets-, kvote- og saldokontrollene uten å bestille. Svarer 200 med OrderPreview, eller med samme feil som en ekte bestilling.","schema":{"type":"boolean"}}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"type":"object","description":"Ingen felt. Fornyelsen gjelder alltid domenets minste fornyelsesperiode."}}}},"responses":{"200":{"description":"dryRun: kontrollene passerte","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrderPreview"}}}},"202":{"description":"Fornyet","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PlaceResult"}}}},"401":{"description":"unauthorized: ugyldig eller manglende nøkkel","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"insufficient_balance","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"forbidden_scope, api_disabled eller ordering_blocked","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"conflict: åpen fornyelse, ukjent utfall eller allerede fornyet","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"rate_limited (120 per minutt per nøkkel) eller order_limit_reached","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"502":{"description":"provisioning_failed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"reconciliation_required eller norid_busy","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/domains/{id}/declaration-link":{"post":{"summary":"Lag en ny lenke til egenerklæringen","description":"Den forrige lenken slutter å virke. Bare for .no-domener som venter på erklæring. Maks 10 per domene per time. Krever bestillingsscopet fordi den sendte lenken blir ugyldig.","tags":["Domener"],"x-required-scope":"domains:order","security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"description":"Domene-ID","schema":{"type":"string","format":"uuid"}}],"responses":{"200":{"description":"Ny lenke","content":{"application/json":{"schema":{"type":"object","required":["declarationUrl"],"properties":{"declarationUrl":{"type":"string","format":"uri"}}}}}},"401":{"description":"unauthorized: ugyldig eller manglende nøkkel","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"forbidden_scope, api_disabled eller ordering_blocked","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"not_found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"conflict: domenet venter ikke på egenerklæring","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"rate_limited (120 per minutt per nøkkel) eller order_limit_reached","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/domains/{id}/nameservers":{"put":{"summary":"Bytt navnetjenere","tags":["Domener"],"x-required-scope":"domains:write","security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"description":"Domene-ID","schema":{"type":"string","format":"uuid"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/NameserversRequest"},"example":{"nameservers":["ns1.norgesdns.no","ns2.norgesdns.no"]}}}},"responses":{"200":{"description":"Byttet","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"nameservers":{"type":"array","items":{"type":"string"}}}}}}},"400":{"description":"invalid_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"unauthorized: ugyldig eller manglende nøkkel","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"forbidden_scope, api_disabled eller ordering_blocked","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"not_found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"rate_limited (120 per minutt per nøkkel) eller order_limit_reached","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"502":{"description":"provisioning_failed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"norid_busy","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/domains/{id}/dns":{"get":{"summary":"List DNS-oppføringer","tags":["DNS"],"x-required-scope":"dns:read","security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"description":"Domene-ID","schema":{"type":"string","format":"uuid"}}],"responses":{"200":{"description":"Oppføringer","content":{"application/json":{"schema":{"type":"object","required":["records"],"properties":{"records":{"type":"array","items":{"$ref":"#/components/schemas/DnsRecord"}}}}}}},"401":{"description":"unauthorized: ugyldig eller manglende nøkkel","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"forbidden_scope, api_disabled eller ordering_blocked","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"not_found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"rate_limited (120 per minutt per nøkkel) eller order_limit_reached","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"post":{"summary":"Opprett en DNS-oppføring","tags":["DNS"],"x-required-scope":"dns:write","security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"description":"Domene-ID","schema":{"type":"string","format":"uuid"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DnsRecordInput"},"example":{"type":"A","name":"@","value":"192.0.2.10","ttl":3600}}}},"responses":{"201":{"description":"Opprettet","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DnsRecord"}}}},"400":{"description":"invalid_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"unauthorized: ugyldig eller manglende nøkkel","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"forbidden_scope, api_disabled eller ordering_blocked","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"not_found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"rate_limited (120 per minutt per nøkkel) eller order_limit_reached","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"502":{"description":"provisioning_failed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/domains/{id}/dns/{recordId}":{"put":{"summary":"Endre en DNS-oppføring","tags":["DNS"],"x-required-scope":"dns:write","security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"description":"Domene-ID","schema":{"type":"string","format":"uuid"}},{"name":"recordId","in":"path","required":true,"description":"Oppførings-ID","schema":{"type":"string","format":"uuid"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DnsRecordInput"},"example":{"type":"A","name":"@","value":"192.0.2.10","ttl":3600}}}},"responses":{"200":{"description":"Endret","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DnsRecord"}}}},"400":{"description":"invalid_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"unauthorized: ugyldig eller manglende nøkkel","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"forbidden_scope, api_disabled eller ordering_blocked","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"not_found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"rate_limited (120 per minutt per nøkkel) eller order_limit_reached","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"502":{"description":"provisioning_failed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"delete":{"summary":"Slett en DNS-oppføring","tags":["DNS"],"x-required-scope":"dns:write","security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"description":"Domene-ID","schema":{"type":"string","format":"uuid"}},{"name":"recordId","in":"path","required":true,"description":"Oppførings-ID","schema":{"type":"string","format":"uuid"}}],"responses":{"204":{"description":"Slettet"},"401":{"description":"unauthorized: ugyldig eller manglende nøkkel","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"forbidden_scope, api_disabled eller ordering_blocked","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"not_found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"rate_limited (120 per minutt per nøkkel) eller order_limit_reached","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"502":{"description":"provisioning_failed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/orders/{id}":{"get":{"summary":"Hent status for en ordre","tags":["Bestilling"],"x-required-scope":"domains:read","security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"description":"Ordre-ID","schema":{"type":"string","format":"uuid"}}],"responses":{"200":{"description":"Ordren","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Order"}}}},"401":{"description":"unauthorized: ugyldig eller manglende nøkkel","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"forbidden_scope, api_disabled eller ordering_blocked","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"not_found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"rate_limited (120 per minutt per nøkkel) eller order_limit_reached","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/account":{"get":{"summary":"Saldo og status for API-bestilling","tags":["Konto"],"x-required-scope":"domains:read","security":[{"bearerAuth":[]}],"responses":{"200":{"description":"Kontoen","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Account"}}}},"401":{"description":"unauthorized: ugyldig eller manglende nøkkel","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"forbidden_scope, api_disabled eller ordering_blocked","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"rate_limited (120 per minutt per nøkkel) eller order_limit_reached","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}}},"webhooks":{"domain.transfer.completed":{"post":{"summary":"domain.transfer.completed","description":"Signert med X-Norgesdomene-Signature: t=<unix>,v1=<HMAC-SHA256 av «t.rå kropp»>. Svar 2xx. Vi prøver på nytt etter 1, 5 og 25 minutter, 2 og 10 timer.","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/WebhookEvent"}}}},"responses":{"200":{"description":"Mottatt"}}}},"domain.transfer.failed":{"post":{"summary":"domain.transfer.failed","description":"Signert med X-Norgesdomene-Signature: t=<unix>,v1=<HMAC-SHA256 av «t.rå kropp»>. Svar 2xx. Vi prøver på nytt etter 1, 5 og 25 minutter, 2 og 10 timer.","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/WebhookEvent"}}}},"responses":{"200":{"description":"Mottatt"}}}},"domain.declaration.signed":{"post":{"summary":"domain.declaration.signed","description":"Signert med X-Norgesdomene-Signature: t=<unix>,v1=<HMAC-SHA256 av «t.rå kropp»>. Svar 2xx. Vi prøver på nytt etter 1, 5 og 25 minutter, 2 og 10 timer.","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/WebhookEvent"}}}},"responses":{"200":{"description":"Mottatt"}}}},"domain.registered":{"post":{"summary":"domain.registered","description":"Signert med X-Norgesdomene-Signature: t=<unix>,v1=<HMAC-SHA256 av «t.rå kropp»>. Svar 2xx. Vi prøver på nytt etter 1, 5 og 25 minutter, 2 og 10 timer.","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/WebhookEvent"}}}},"responses":{"200":{"description":"Mottatt"}}}},"domain.registration.failed":{"post":{"summary":"domain.registration.failed","description":"Signert med X-Norgesdomene-Signature: t=<unix>,v1=<HMAC-SHA256 av «t.rå kropp»>. Svar 2xx. Vi prøver på nytt etter 1, 5 og 25 minutter, 2 og 10 timer.","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/WebhookEvent"}}}},"responses":{"200":{"description":"Mottatt"}}}},"domain.renewed":{"post":{"summary":"domain.renewed","description":"Signert med X-Norgesdomene-Signature: t=<unix>,v1=<HMAC-SHA256 av «t.rå kropp»>. Svar 2xx. Vi prøver på nytt etter 1, 5 og 25 minutter, 2 og 10 timer.","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/WebhookEvent"}}}},"responses":{"200":{"description":"Mottatt"}}}}},"components":{"securitySchemes":{"bearerAuth":{"type":"http","scheme":"bearer","description":"API-nøkkel (ndp_live_…) fra kundeportalen. Bruk bare fra egen server. Scopes: domains:read, domains:write, dns:read, dns:write, domains:order. Hver operasjon oppgir scopet i x-required-scope."}},"schemas":{"Error":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["code","message"],"properties":{"code":{"type":"string","enum":["unauthorized","forbidden_scope","api_disabled","ordering_blocked","rate_limited","order_limit_reached","invalid_request","domain_taken","conflict","invalid_contact","insufficient_balance","provisioning_failed","availability_unavailable","reconciliation_required","not_found","norid_busy"]},"message":{"type":"string"},"retryAt":{"type":"string","format":"date-time","description":"Bare for norid_busy"}}}}},"Registrant":{"type":"object","required":["type","name","email"],"description":"organisasjon krever orgNumber; person krever personId (N.PRI.xxxxxxxx).","properties":{"type":{"type":"string","enum":["person","organisasjon"]},"name":{"type":"string","maxLength":200},"orgNumber":{"type":"string","pattern":"^\\d{9}$"},"personId":{"type":"string"},"email":{"type":"string","format":"email"},"phone":{"type":"string"},"addressLine1":{"type":"string"},"postalCode":{"type":"string"},"city":{"type":"string"},"country":{"type":"string","minLength":2,"maxLength":2,"default":"NO"}}},"RegisterRequest":{"type":"object","required":["domain","registrant"],"properties":{"domain":{"type":"string","description":"Bare .no i denne versjonen"},"period":{"type":"integer","minimum":1,"maximum":10},"registrant":{"$ref":"#/components/schemas/Registrant"},"nameservers":{"type":"array","items":{"type":"string"},"maxItems":13},"domainPrivacy":{"type":"boolean","default":false,"description":"Skjerm innehaverens e-post: Norid får en tilfeldig adresse hos domainprivacy.no som filtrerer og videresender til innehaveren. Videresendt post viser Norgesdomene som avsender. Gjelder først når funksjonen er åpnet for alle kunder; før det ignoreres feltet."}}},"TransferRequest":{"type":"object","required":["domain"],"description":"authCode kreves, unntatt for .no-domener uten registrar (noRegistrar: true).","properties":{"domain":{"type":"string"},"authCode":{"type":"string","maxLength":255},"noRegistrar":{"type":"boolean"}}},"PlaceResult":{"type":"object","required":["orderId","domain","status","declarationUrl"],"properties":{"orderId":{"type":"string","format":"uuid"},"orderNumber":{"type":["integer","null"]},"domain":{"type":"string"},"status":{"type":"string","enum":["pendingRegistration","pendingTransfer","pendingRenewal","active"]},"declarationUrl":{"type":["string","null"],"format":"uri"}}},"OrderPreview":{"type":"object","required":["dryRun","action","domain","totalOre","balanceOre","balanceAfterOre","dailyOrdersRemaining"],"properties":{"dryRun":{"const":true},"action":{"type":"string","enum":["register","transfer","renew"]},"domain":{"type":"string"},"subtotalOre":{"type":"integer"},"vatOre":{"type":"integer"},"totalOre":{"type":"integer"},"currency":{"const":"NOK"},"balanceOre":{"type":"integer"},"balanceAfterOre":{"type":"integer"},"dailyOrdersRemaining":{"type":"integer"},"declarationRequired":{"type":"boolean"}}},"AvailabilityResult":{"type":"object","required":["domain","available"],"properties":{"domain":{"type":"string"},"available":{"type":"boolean"},"reason":{"type":"string"},"priceOre":{"type":"integer"},"vatOre":{"type":"integer"},"totalOre":{"type":"integer"},"currency":{"const":"NOK"}}},"DomainSummary":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"name":{"type":"string"},"status":{"type":"string"},"expiresAt":{"type":["string","null"],"format":"date"},"registrar":{"type":"string"},"autoRenew":{"type":"boolean"}}},"DomainDetail":{"allOf":[{"$ref":"#/components/schemas/DomainSummary"},{"type":"object","properties":{"declaration":{"type":"string","enum":["pending","signed","not_required"]},"declarationUrl":{"type":["string","null"],"format":"uri"}}}]},"UpdateDomainRequest":{"type":"object","required":["autoRenew"],"additionalProperties":false,"properties":{"autoRenew":{"type":"boolean"}}},"UpdateDomainResult":{"type":"object","properties":{"id":{"type":"string"},"autoRenew":{"type":"boolean"},"changed":{"type":"boolean"},"billing":{"type":"object","properties":{"outcome":{"type":"string"},"message":{"type":["string","null"]}}}}},"NameserversRequest":{"type":"object","required":["nameservers"],"properties":{"nameservers":{"type":"array","items":{"type":"string"},"minItems":1,"maxItems":13}}},"DnsRecordInput":{"type":"object","required":["type","value"],"properties":{"type":{"type":"string","enum":["A","AAAA","CNAME","TXT","MX","SRV","CAA"]},"name":{"type":"string","maxLength":253,"description":"Tom eller @ for apex"},"value":{"type":"string","maxLength":4096},"ttl":{"type":"integer","minimum":0,"default":3600},"priority":{"type":["integer","null"],"minimum":0,"maximum":65535},"weight":{"type":["integer","null"],"minimum":0,"maximum":65535},"flags":{"type":["integer","null"],"minimum":0,"maximum":255},"tag":{"type":["string","null"]},"port":{"type":["integer","null"],"minimum":0,"maximum":65535},"disabled":{"type":"boolean","default":false}}},"DnsRecord":{"allOf":[{"$ref":"#/components/schemas/DnsRecordInput"},{"type":"object","required":["id"],"properties":{"id":{"type":"string","format":"uuid"}}}]},"Order":{"type":"object","properties":{"orderId":{"type":"string","format":"uuid"},"orderNumber":{"type":["integer","null"]},"status":{"type":"string"},"reconciliationRequired":{"type":"boolean"},"totalOre":{"type":"integer"},"items":{"type":"array","items":{"type":"object","properties":{"kind":{"type":"string"},"description":{"type":"string"},"meta":{"type":"object","properties":{"domain":{"type":"string"},"action":{"type":"string","enum":["register","renew","transfer-in"]},"period":{"type":"integer"}}}}}}}},"Account":{"type":"object","properties":{"balanceOre":{"type":"integer"},"currency":{"const":"NOK"},"ordering":{"type":"object","properties":{"status":{"type":"string","enum":["active","not_activated","blocked"]},"dailyOrderLimit":{"type":"integer"},"keyCanOrder":{"type":"boolean"}}}}},"WebhookEvent":{"type":"object","required":["event","createdAt","data"],"properties":{"event":{"type":"string","enum":["domain.transfer.completed","domain.transfer.failed","domain.declaration.signed","domain.registered","domain.registration.failed","domain.renewed"]},"createdAt":{"type":"string","format":"date-time"},"data":{"type":"object","description":"Alltid domainId og domain. Ellers etter hendelse: orderId, expiresAt, reason, awaitingReview.","properties":{"domainId":{"type":"string","format":"uuid"},"domain":{"type":"string"},"orderId":{"type":["string","null"]},"expiresAt":{"type":["string","null"]},"reason":{"type":"string"},"awaitingReview":{"type":"boolean"}}}}}}}}