{"record":{"id":"197202cee7a3125e","repo":"ipfs/kubo","slug":"no-delegated-publishers-configured-add-ipns-deleg","errorCode":null,"errorMessage":"no delegated publishers configured: add Ipns.DelegatedPublishers or use --allow-offline for local-only publishing","messagePattern":"no delegated publishers configured: add Ipns\\.DelegatedPublishers or use --allow-offline for local-only publishing","errorType":"validation","errorClass":null,"httpStatus":null,"severity":"error","filePath":"core/commands/name/name.go","lineNumber":458,"sourceCode":"\t\tforce, _ := req.Options[forceOptionName].(bool)\n\t\tallowOffline, _ := req.Options[putAllowOfflineOption].(bool)\n\t\tallowDelegated, _ := req.Options[allowDelegatedOption].(bool)\n\n\t\t// Validate flag combinations\n\t\tif allowOffline && allowDelegated {\n\t\t\treturn errors.New(\"cannot use both --allow-offline and --allow-delegated flags\")\n\t\t}\n\n\t\t// Handle different publishing modes\n\t\tif allowDelegated {\n\t\t\t// AllowDelegated mode: check if delegated publishers are configured\n\t\t\tcfg, err := nd.Repo.Config()\n\t\t\tif err != nil {\n\t\t\t\treturn fmt.Errorf(\"failed to read config: %w\", err)\n\t\t\t}\n\t\t\tdelegatedPublishers := cfg.DelegatedPublishersWithAutoConf()\n\t\t\tif len(delegatedPublishers) == 0 {\n\t\t\t\treturn errors.New(\"no delegated publishers configured: add Ipns.DelegatedPublishers or use --allow-offline for local-only publishing\")\n\t\t\t}\n\t\t\t// For allow-delegated mode, we proceed even if offline\n\t\t\t// since we're using HTTP publishing via delegated publishers\n\t\t}\n\n\t\t// Parse the IPNS name argument\n\t\tnameArg := req.Arguments[0]\n\t\tif !strings.HasPrefix(nameArg, \"/ipns/\") {\n\t\t\tnameArg = \"/ipns/\" + nameArg\n\t\t}\n\t\t// Extract the name part after /ipns/\n\t\tnamePart := strings.TrimPrefix(nameArg, \"/ipns/\")\n\t\tname, err := ipns.NameFromString(namePart)\n\t\tif err != nil {\n\t\t\treturn fmt.Errorf(\"invalid IPNS name: %w\", err)\n\t\t}\n\n\t\t// Read raw record bytes from file/stdin","sourceCodeStart":440,"sourceCodeEnd":476,"githubUrl":"https://github.com/ipfs/kubo/blob/329838acdfafae224582930457efe80aa217afc0/core/commands/name/name.go#L440-L476","documentation":"`ipfs ipns put --allow-delegated` requires at least one entry in Ipns.DelegatedPublishers (after AutoConf expansion). If cfg.DelegatedPublishersWithAutoConf() returns an empty list, publishing to delegated endpoints is impossible, so the command stops and points the user at the config option or the --allow-offline alternative.","triggerScenarios":"`ipfs ipns put --allow-delegated ...` on a node where Ipns.DelegatedPublishers is empty and AutoConf does not supply defaults (e.g. AutoConf disabled or unreachable).","commonSituations":"Fresh nodes without delegated publisher configuration, AutoConf turned off in config, or air-gapped setups where auto-discovery of publishers cannot run.","solutions":["Configure publishers: `ipfs config --json Ipns.DelegatedPublishers '[\"https://publisher.example\"]'`","Ensure AutoConf is enabled/reachable so defaults can populate the list","Use `--allow-offline` instead if local-only publishing is acceptable"],"exampleFix":"// before\nipfs ipns put --allow-delegated --key=self record.bin\n// error: no delegated publishers configured: ...\n// after\nipfs config --json Ipns.DelegatedPublishers '[\"https://delegated-publisher.example\"]'\nipfs ipns put --allow-delegated --key=self record.bin","handlingStrategy":"validation","validationCode":"// pre-check before invoking with --allow-delegated\ncfg, _ := node.Repo.Config()\npubs := cfg.DelegatedPublishersWithAutoConf()\nif len(pubs) == 0 { /* configure publishers or use --allow-offline */ }","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Configure Ipns.DelegatedPublishers before using --allow-delegated","Keep AutoConf enabled if relying on discovered defaults"],"tags":["ipns","config","delegated-publishing"],"backgroundTag":"missing-config-value","analyzedSha":"329838acdfafae224582930457efe80aa217afc0","analyzedAt":"2026-09-03T18:30:52.135Z","contentChangedAt":"2026-09-03T18:30:52.135Z","schemaVersion":2},"datasetVersion":"2026-09-11T00:17:11.886Z"}