{"record":{"id":"44daf5ae2b97aa7a","repo":"pulumi/pulumi","slug":"the-builtin-provider-does-not-implement-call","errorCode":null,"errorMessage":"the builtin provider does not implement call","messagePattern":"the builtin provider does not implement call","errorType":"error_code","errorClass":null,"httpStatus":null,"severity":"error","filePath":"pkg/resource/deploy/builtins.go","lineNumber":358,"sourceCode":"\tvar err error\n\tswitch req.Tok {\n\tcase readStackOutputs:\n\t\touts, err = p.readStackReference(ctx, req.Args)\n\tcase readStackResourceOutputs:\n\t\touts, err = p.readStackResourceOutputs(req.Args)\n\tcase getResource:\n\t\touts, err = p.getResource(req.Args)\n\tdefault:\n\t\terr = fmt.Errorf(\"unrecognized function name: '%v'\", req.Tok)\n\t}\n\tif err != nil {\n\t\treturn plugin.InvokeResponse{}, err\n\t}\n\treturn plugin.InvokeResponse{Properties: outs}, nil\n}\n\nfunc (p *builtinProvider) Call(context.Context, plugin.CallRequest) (plugin.CallResponse, error) {\n\treturn plugin.CallResult{}, errors.New(\"the builtin provider does not implement call\")\n}\n\nfunc (p *builtinProvider) GetPluginInfo(context.Context) (plugin.PluginInfo, error) {\n\t// return an error: this should not be called for the builtin provider\n\treturn plugin.PluginInfo{}, errors.New(\"the builtin provider does not report plugin info\")\n}\n\nfunc (p *builtinProvider) SignalCancellation(context.Context) error {\n\tp.cancel()\n\treturn nil\n}\n\nfunc (p *builtinProvider) readStackReference(\n\tctx context.Context, inputs property.Map,\n) (property.Map, error) {\n\ttracer := otel.Tracer(\"pulumi-cli\")\n\tctx, span := cmdutil.StartSpan(ctx, tracer, \"builtinProvider.readStackReference\")\n\tdefer span.End()","sourceCodeStart":340,"sourceCodeEnd":376,"githubUrl":"https://github.com/pulumi/pulumi/blob/793f7b2e160db4321fb7fb6b0607461e01cb251e/pkg/resource/deploy/builtins.go#L340-L376","documentation":"The builtin provider implements only Invoke for functions; provider-level Call (used for multi-function call dispatch, e.g. some SDK `call` operations on components) is not implemented and always returns this error from builtinProvider.Call.","triggerScenarios":"The engine issues a `CallRequest` to the builtin provider — i.e. a program uses the SDK's `call` operation (rather than `invoke`) against a function or component method that resolves to the builtin provider's `pulumi:pulumi:*` tokens.","commonSituations":"Newer language SDKs using the call-based ComponentResource/output-binding path against an engine whose builtin provider predates Call support; custom tooling converting invokes to calls.","solutions":["Use `invoke` (the plain function-invoke path) instead of `call` for `pulumi:pulumi:*` builtin functions.","Upgrade the Pulumi CLI/engine to a version where builtin `pulumi:pulumi:*` functions are exposed in a callable form, or use an SDK wrapper backed by Invoke.","If you need Call support in the builtin provider (engine development), implement builtinProvider.Call in builtins.go:357."],"exampleFix":"// before\nres, err := pulumi.Call(ctx, \"pulumi:pulumi:readStackOutputs\", args)\n// after\nres, err := pulumi.Invoke(ctx, \"pulumi:pulumi:readStackOutputs\", args)","handlingStrategy":"fallback","validationCode":"const invokeOnlyTokens = new Set([\n  'pulumi:pulumi:readStackOutputs',\n  'pulumi:pulumi:readStackResourceOutputs',\n  'pulumi:pulumi:getResource',\n])\nfunction assertNotCallOnBuiltin(tok) {\n  if (invokeOnlyTokens.has(tok)) throw new Error('Use invoke, not call, for builtin pulumi:pulumi:* functions')\n}","typeGuard":"null","tryCatchPattern":"try {\n  return await call(tok, args)\n} catch (e) {\n  if (String(e).includes('does not implement call')) {\n    return await invoke(tok, args) // fallback to invoke for builtin functions\n  }\n  throw e\n}","preventionTips":["Prefer `invoke` for pulumi:pulumi:* builtin functions.","Check SDK docs for whether an operation is call-based or invoke-based before use.","Keep engine at a version supporting your SDK's call path for non-builtin providers."],"tags":["go","pulumi-engine","builtin-provider","call-vs-invoke"],"backgroundTag":"unsupported-provider-operation","analyzedSha":"793f7b2e160db4321fb7fb6b0607461e01cb251e","analyzedAt":"2026-08-31T09:36:43.099Z","schemaVersion":2},"datasetVersion":"2026-09-01T08:17:40.651Z"}