{"record":{"id":"4de9da7139980ad0","repo":"ipfs/kubo","slug":"service-not-known","errorCode":null,"errorMessage":"service not known","messagePattern":"service not known","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"core/commands/pin/remotepin.go","lineNumber":780,"sourceCode":"\treturn pinclient.NewClient(endpoint, key), nil\n}\n\nfunc getRemotePinServiceInfo(env cmds.Environment, name string) (endpoint, key string, err error) {\n\tcfgRoot, err := cmdenv.GetConfigRoot(env)\n\tif err != nil {\n\t\treturn \"\", \"\", err\n\t}\n\trepo, err := fsrepo.Open(cfgRoot)\n\tif err != nil {\n\t\treturn \"\", \"\", err\n\t}\n\tdefer repo.Close()\n\tcfg, err := repo.Config()\n\tif err != nil {\n\t\treturn \"\", \"\", err\n\t}\n\tif cfg.Pinning.RemoteServices == nil {\n\t\treturn \"\", \"\", fmt.Errorf(\"service not known\")\n\t}\n\tservice, present := cfg.Pinning.RemoteServices[name]\n\tif !present {\n\t\treturn \"\", \"\", fmt.Errorf(\"service not known\")\n\t}\n\tendpoint, err = normalizeEndpoint(service.API.Endpoint)\n\tif err != nil {\n\t\treturn \"\", \"\", err\n\t}\n\treturn endpoint, service.API.Key, nil\n}\n\nfunc normalizeEndpoint(endpoint string) (string, error) {\n\turi, err := neturl.ParseRequestURI(endpoint)\n\tif err != nil || !(uri.Scheme == \"http\" || uri.Scheme == \"https\") {\n\t\treturn \"\", fmt.Errorf(\"service endpoint must be a valid HTTP URL\")\n\t}\n","sourceCodeStart":762,"sourceCodeEnd":798,"githubUrl":"https://github.com/ipfs/kubo/blob/329838acdfafae224582930457efe80aa217afc0/core/commands/pin/remotepin.go#L762-L798","documentation":"`getRemotePinServiceInfo` looks up endpoint and API key for a service name in `Pinning.RemoteServices`. When the config map itself is nil (no remote services have ever been configured on this node), it cannot resolve the name and returns `service not known`. This is the nil-map branch of the same lookup that also fails when the map exists but lacks the name (see error 425).","triggerScenarios":"Any `pin remote` operation referencing a service via `--service=<name>` on a node where `Pinning.RemoteServices` is nil — i.e. the service was never added with `ipfs pin remote add` (service registration) and no services exist in the config at all.","commonSituations":"Fresh node or fresh IPFS_PATH where the service setup step was skipped; pointing the CLI at the wrong repo (wrong IPFS_PATH) that has no services configured; config migration/reset wiped Pinning.RemoteServices.","solutions":["Register the service first: `ipfs pin remote add <name> <endpoint> --key=<apikey>` (service-add command), then retry.","Verify you are operating on the right repo: check `$IPFS_PATH` and confirm the service exists via `ipfs config Pinning.RemoteServices --json`.","If the config was wiped, re-add all services from your provisioning scripts/backups.","Inspect `~/.ipfs/config` (or `$IPFS_PATH/config`) directly to confirm the `Pinning.RemoteServices` key exists."],"exampleFix":"// before\nipfs pin remote ls --service=pinata   # node has no services configured\n// after\nipfs pin remote add pinata https://api.pinata.cloud/psa --key=$PINATA_JWT\nipfs pin remote ls --service=pinata","handlingStrategy":"validation","validationCode":"#!/usr/bin/env bash\n# ensure the repo has any remote services configured\nif ! ipfs config Pinning.RemoteServices --json 2>/dev/null | grep -q 'Pinata\\|web3\\| Filebase\\|storage'; then\n  echo \"no remote pinning services configured; run 'ipfs pin remote add ...' first\" >&2\n  exit 1\nfi","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Register services as part of node init/provisioning before using pin remote","Confirm IPFS_PATH points at the repo where services were configured","Back up the config section so wiped configs can be restored"],"tags":["config","remote-pinning","lookup-failed","missing-config"],"backgroundTag":"resource-not-found","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"}