@codedrifters/configulator 0.0.155 → 0.0.156

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/lib/index.d.mts CHANGED
@@ -683,6 +683,19 @@ declare class AgentConfig extends Component {
683
683
  private resolveRules;
684
684
  private resolveSkills;
685
685
  private resolveSubAgents;
686
+ /**
687
+ * Resolves template variables in rule content using project metadata.
688
+ * Emits synthesis warnings for rules with unresolved variables.
689
+ */
690
+ private resolveTemplates;
691
+ /**
692
+ * Resolves template variables in skill instructions using project metadata.
693
+ */
694
+ private resolveSkillTemplates;
695
+ /**
696
+ * Resolves template variables in sub-agent prompts using project metadata.
697
+ */
698
+ private resolveSubAgentTemplates;
686
699
  }
687
700
 
688
701
  /**
@@ -737,6 +750,259 @@ declare const vitestBundle: AgentRuleBundle;
737
750
  */
738
751
  declare const BUILT_IN_BUNDLES: ReadonlyArray<AgentRuleBundle>;
739
752
 
753
+ /*******************************************************************************
754
+ *
755
+ * Repository Metadata
756
+ *
757
+ ******************************************************************************/
758
+ /**
759
+ * Repository identity. Required fields are auto-detected when not provided.
760
+ */
761
+ interface RepositoryMetadata {
762
+ /**
763
+ * Repository owner (GitHub user or organization).
764
+ * Auto-detected from package.json repository URL when not provided.
765
+ * @example 'codedrifters'
766
+ */
767
+ readonly owner?: string;
768
+ /**
769
+ * Repository name.
770
+ * Auto-detected from package.json repository URL when not provided.
771
+ * @example 'packages'
772
+ */
773
+ readonly name?: string;
774
+ /**
775
+ * Default branch name.
776
+ * @default 'main'
777
+ */
778
+ readonly defaultBranch?: string;
779
+ }
780
+ /*******************************************************************************
781
+ *
782
+ * GitHub Projects Metadata
783
+ *
784
+ ******************************************************************************/
785
+ /**
786
+ * A board or view within a GitHub Project.
787
+ */
788
+ interface GitHubBoardMetadata {
789
+ /** Board/view name. */
790
+ readonly name: string;
791
+ /** Board/view ID. */
792
+ readonly id?: string;
793
+ }
794
+ /**
795
+ * Sprint/iteration field metadata for GitHub Projects.
796
+ */
797
+ interface GitHubSprintMetadata {
798
+ /** Name of the iteration field in GitHub Projects. */
799
+ readonly fieldName?: string;
800
+ /** Current sprint/iteration name. */
801
+ readonly current?: string;
802
+ /** Known sprint/iteration names. */
803
+ readonly iterations?: ReadonlyArray<string>;
804
+ }
805
+ /**
806
+ * GitHub Projects (v2) context for workflow automation.
807
+ */
808
+ interface GitHubProjectMetadata {
809
+ /**
810
+ * GitHub Project name.
811
+ * @example 'CodeDrifters Packages'
812
+ */
813
+ readonly name?: string;
814
+ /**
815
+ * GitHub Project number (visible in the project URL).
816
+ * @example 3
817
+ */
818
+ readonly number?: number;
819
+ /**
820
+ * GitHub Project node ID (for GraphQL API).
821
+ * @example 'PVT_kwHOABCDEf4AGHIJ'
822
+ */
823
+ readonly nodeId?: string;
824
+ /**
825
+ * Board or view definitions within the project.
826
+ */
827
+ readonly boards?: ReadonlyArray<GitHubBoardMetadata>;
828
+ /**
829
+ * Sprint/iteration field metadata.
830
+ */
831
+ readonly sprints?: GitHubSprintMetadata;
832
+ /**
833
+ * Kanban column (status field) definitions.
834
+ * @example [{ name: 'To Do', id: 'status_1' }, { name: 'In Progress', id: 'status_2' }]
835
+ */
836
+ readonly columns?: ReadonlyArray<{
837
+ readonly name: string;
838
+ readonly id?: string;
839
+ }>;
840
+ }
841
+ /*******************************************************************************
842
+ *
843
+ * Organization Metadata
844
+ *
845
+ ******************************************************************************/
846
+ /**
847
+ * Organization or team context.
848
+ */
849
+ interface OrganizationMetadata {
850
+ /**
851
+ * Organization or team display name.
852
+ * Used in generated documentation and rule content.
853
+ * @example 'CodeDrifters'
854
+ */
855
+ readonly name?: string;
856
+ /**
857
+ * GitHub organization login (may differ from display name).
858
+ * @example 'codedrifters'
859
+ */
860
+ readonly githubOrg?: string;
861
+ }
862
+ /*******************************************************************************
863
+ *
864
+ * Slack Metadata
865
+ *
866
+ ******************************************************************************/
867
+ /**
868
+ * Slack channel references for workflow skills.
869
+ */
870
+ interface SlackMetadata {
871
+ /**
872
+ * Primary project channel.
873
+ * @example '#packages-dev'
874
+ */
875
+ readonly projectChannel?: string;
876
+ /**
877
+ * Alerts or notifications channel.
878
+ * @example '#packages-alerts'
879
+ */
880
+ readonly alertsChannel?: string;
881
+ /**
882
+ * Additional named channels. Keys are purpose identifiers.
883
+ * @example { releases: '#releases', support: '#customer-support' }
884
+ */
885
+ readonly channels?: Readonly<Record<string, string>>;
886
+ }
887
+ /*******************************************************************************
888
+ *
889
+ * Deployment Metadata
890
+ *
891
+ ******************************************************************************/
892
+ /**
893
+ * Deployment and environment hints.
894
+ */
895
+ interface DeploymentMetadata {
896
+ /**
897
+ * AWS account ID for the primary deployment target.
898
+ * @example '123456789012'
899
+ */
900
+ readonly awsAccountId?: string;
901
+ /**
902
+ * Primary AWS region.
903
+ * @example 'us-east-1'
904
+ */
905
+ readonly awsRegion?: string;
906
+ /**
907
+ * Named environments.
908
+ * @example { dev: { accountId: '111', region: 'us-east-1' }, prod: { accountId: '222', region: 'us-east-1' } }
909
+ */
910
+ readonly environments?: Readonly<Record<string, {
911
+ readonly accountId?: string;
912
+ readonly region?: string;
913
+ }>>;
914
+ }
915
+ /*******************************************************************************
916
+ *
917
+ * ProjectMetadata Options & Resolved Shape
918
+ *
919
+ ******************************************************************************/
920
+ /**
921
+ * Options for the ProjectMetadata component.
922
+ */
923
+ interface ProjectMetadataOptions {
924
+ /**
925
+ * Repository identity. When omitted, auto-detected from the Projen
926
+ * project's package.json repository field.
927
+ */
928
+ readonly repository?: RepositoryMetadata;
929
+ /**
930
+ * GitHub Projects (v2) context for workflow automation.
931
+ * Optional — only needed when skills or rules reference project boards.
932
+ */
933
+ readonly githubProject?: GitHubProjectMetadata;
934
+ /**
935
+ * Organization or team metadata.
936
+ * Optional — used in branch naming, PR conventions, and rule content.
937
+ */
938
+ readonly organization?: OrganizationMetadata;
939
+ /**
940
+ * Slack channel references for workflow skills.
941
+ * Optional — only needed when skills post to or reference Slack channels.
942
+ */
943
+ readonly slack?: SlackMetadata;
944
+ /**
945
+ * Important label names used by the project.
946
+ * Optional — allows skills and rules to reference canonical labels.
947
+ * @example ['auto-approve', 'wontfix', 'breaking-change']
948
+ */
949
+ readonly labels?: ReadonlyArray<string>;
950
+ /**
951
+ * Milestone names or IDs for release planning.
952
+ * Optional — allows skills to reference milestones by name.
953
+ */
954
+ readonly milestones?: ReadonlyArray<string>;
955
+ /**
956
+ * Documentation base path (relative to repo root) or external URL.
957
+ * Optional — used by "reference docs" skills to point to the right location.
958
+ * @example 'docs/' or 'https://docs.example.com'
959
+ */
960
+ readonly docsPath?: string;
961
+ /**
962
+ * Deployment or environment hints.
963
+ * Optional — used by deploy-related skills or rules.
964
+ */
965
+ readonly deployment?: DeploymentMetadata;
966
+ }
967
+ /**
968
+ * Resolved project metadata with auto-detected values filled in.
969
+ * Consumed by AgentConfig and other configulator features at synthesis time.
970
+ */
971
+ interface ResolvedProjectMetadata {
972
+ readonly repository: {
973
+ readonly owner: string | undefined;
974
+ readonly name: string | undefined;
975
+ /** Always has a value (default: 'main'). */
976
+ readonly defaultBranch: string;
977
+ };
978
+ readonly githubProject?: GitHubProjectMetadata;
979
+ readonly organization?: OrganizationMetadata;
980
+ readonly slack?: SlackMetadata;
981
+ readonly labels?: ReadonlyArray<string>;
982
+ readonly milestones?: ReadonlyArray<string>;
983
+ readonly docsPath?: string;
984
+ readonly deployment?: DeploymentMetadata;
985
+ }
986
+
987
+ /**
988
+ * Result of template variable resolution.
989
+ */
990
+ interface TemplateResolveResult {
991
+ /** The template string with all variables resolved or replaced with fallbacks. */
992
+ readonly resolved: string;
993
+ /** Template variable keys that could not be resolved from metadata. */
994
+ readonly unresolvedKeys: ReadonlyArray<string>;
995
+ }
996
+ /**
997
+ * Resolves `{{dotted.path}}` template variables in a string using project metadata.
998
+ * Unresolved variables are replaced with their fallback placeholders.
999
+ *
1000
+ * @param template - String potentially containing `{{variable}}` patterns
1001
+ * @param metadata - Resolved project metadata, or undefined if not available
1002
+ * @returns The resolved string and a list of any unresolved variable keys
1003
+ */
1004
+ declare function resolveTemplateVariables(template: string, metadata: ResolvedProjectMetadata | undefined): TemplateResolveResult;
1005
+
740
1006
  /*******************************************************************************
741
1007
  *
742
1008
  * Git configs for this repo. This venn diagram has a great deal of overlap
@@ -2046,6 +2312,18 @@ interface MonorepoProjectOptions extends Omit<TypeScriptProjectOptions$1, "defau
2046
2312
  * @default true
2047
2313
  */
2048
2314
  readonly configulatorRegistryConsumer?: boolean;
2315
+ /**
2316
+ * Project metadata configuration. Provides repository identity,
2317
+ * GitHub project context, and organizational details consumed by
2318
+ * AgentConfig and other features at synthesis time.
2319
+ *
2320
+ * - `undefined` or `{}`: auto-instantiate with auto-detection (default)
2321
+ * - `ProjectMetadataOptions`: explicit metadata configuration
2322
+ * - `false`: disable ProjectMetadata entirely
2323
+ *
2324
+ * @default {} (auto-detect from package.json)
2325
+ */
2326
+ readonly projectMetadata?: ProjectMetadataOptions | false;
2049
2327
  /**
2050
2328
  * Enable AI agent configuration (Cursor, Claude Code rules).
2051
2329
  * When true, generates rule files at the monorepo root with auto-detected
@@ -2082,6 +2360,38 @@ declare class MonorepoProject extends TypeScriptAppProject {
2082
2360
  postSynthesize(): void;
2083
2361
  }
2084
2362
 
2363
+ /**
2364
+ * Provides structured project metadata consumed by AgentConfig, skills,
2365
+ * and other configulator features at synthesis time.
2366
+ *
2367
+ * This is a project-level component — it describes the project itself,
2368
+ * not any specific feature. It lives alongside MonorepoProject and
2369
+ * TypeScriptProject and is discovered by consumers via the static
2370
+ * `.of()` factory method.
2371
+ */
2372
+ declare class ProjectMetadata extends Component {
2373
+ /**
2374
+ * Returns the ProjectMetadata instance for a project, or undefined
2375
+ * if the component has not been added.
2376
+ */
2377
+ static of(project: Project$1): ProjectMetadata | undefined;
2378
+ /** Resolved metadata with auto-detected values filled in. */
2379
+ readonly metadata: ResolvedProjectMetadata;
2380
+ constructor(project: Project$1, options?: ProjectMetadataOptions);
2381
+ /**
2382
+ * Merges explicit options with auto-detected values.
2383
+ * Auto-detection reads the repository URL from package.json
2384
+ * (via Projen's NodePackage manifest) and parses GitHub owner/name.
2385
+ * Explicit options always take precedence over auto-detected values.
2386
+ */
2387
+ private resolveMetadata;
2388
+ /**
2389
+ * Attempts to auto-detect repository owner and name from the Projen
2390
+ * project's package.json repository field.
2391
+ */
2392
+ private autoDetectRepository;
2393
+ }
2394
+
2085
2395
  /**
2086
2396
  * Options for the Vitest config (test block in vitest.config).
2087
2397
  *
@@ -2330,4 +2640,4 @@ declare const COMPLETE_JOB_ID = "complete";
2330
2640
  */
2331
2641
  declare function addBuildCompleteJob(buildWorkflow: BuildWorkflow): void;
2332
2642
 
2333
- export { AGENT_MODEL, AGENT_PLATFORM, AGENT_RULE_SCOPE, AgentConfig, type AgentConfigOptions, type AgentModel, type AgentPlatform, type AgentPlatformOverrides, type AgentRule, type AgentRuleBundle, type AgentRuleScope, type AgentSkill, type AgentSubAgent, type AgentSubAgentPlatformOverrides, type ApproveMergeUpgradeOptions, type AwsAccount, AwsDeployWorkflow, AwsDeploymentConfig, AwsDeploymentTarget, type AwsDeploymentTargetOptions, type AwsLocalDeploymentConfig, type AwsOrganization, type AwsRegion, BUILT_IN_BUNDLES, CLAUDE_RULE_TARGET, COMPLETE_JOB_ID, type CiDeploymentConfig, type ClassTypeOptions, type ClaudeAutoModeConfig, type ClaudeHookAction, type ClaudeHookEntry, type ClaudeHooksConfig, type ClaudePermissionsConfig, type ClaudeRuleTarget, type ClaudeSandboxConfig, type ClaudeSettingsConfig, type CursorHookAction, type CursorHooksConfig, type CursorSettingsConfig, type DeployWorkflowOptions, type GitBranch, type IDependencyResolver, JsiiFaker, MCP_TRANSPORT, MERGE_METHODS, MIMIMUM_RELEASE_AGE, type McpServerConfig, type McpTransport, type MergeMethod, MonorepoProject, type MonorepoProjectOptions, PROD_DEPLOY_NAME, PnpmWorkspace, type PnpmWorkspaceOptions, ROOT_CI_TASK_NAME, ROOT_TURBO_TASK_NAME, type RemoteCacheOptions, ResetTask, type ResetTaskOptions, TestRunner, TurboRepo, type TurboRepoOptions, TurboRepoTask, type TurboRepoTaskOptions, TypeScriptConfig, TypeScriptProject, type TypeScriptProjectOptions, VERSION, VERSION_KEYS_SKIP, VERSION_NPM_PACKAGES, VSCodeConfig, type VersionKey, Vitest, type VitestConfigOptions, type VitestOptions, addApproveMergeUpgradeWorkflow, addBuildCompleteJob, awsCdkBundle, baseBundle, getLatestEligibleVersion, jestBundle, pnpmBundle, projenBundle, turborepoBundle, typescriptBundle, vitestBundle };
2643
+ export { AGENT_MODEL, AGENT_PLATFORM, AGENT_RULE_SCOPE, AgentConfig, type AgentConfigOptions, type AgentModel, type AgentPlatform, type AgentPlatformOverrides, type AgentRule, type AgentRuleBundle, type AgentRuleScope, type AgentSkill, type AgentSubAgent, type AgentSubAgentPlatformOverrides, type ApproveMergeUpgradeOptions, type AwsAccount, AwsDeployWorkflow, AwsDeploymentConfig, AwsDeploymentTarget, type AwsDeploymentTargetOptions, type AwsLocalDeploymentConfig, type AwsOrganization, type AwsRegion, BUILT_IN_BUNDLES, CLAUDE_RULE_TARGET, COMPLETE_JOB_ID, type CiDeploymentConfig, type ClassTypeOptions, type ClaudeAutoModeConfig, type ClaudeHookAction, type ClaudeHookEntry, type ClaudeHooksConfig, type ClaudePermissionsConfig, type ClaudeRuleTarget, type ClaudeSandboxConfig, type ClaudeSettingsConfig, type CursorHookAction, type CursorHooksConfig, type CursorSettingsConfig, type DeployWorkflowOptions, type DeploymentMetadata, type GitBranch, type GitHubBoardMetadata, type GitHubProjectMetadata, type GitHubSprintMetadata, type IDependencyResolver, JsiiFaker, MCP_TRANSPORT, MERGE_METHODS, MIMIMUM_RELEASE_AGE, type McpServerConfig, type McpTransport, type MergeMethod, MonorepoProject, type MonorepoProjectOptions, type OrganizationMetadata, PROD_DEPLOY_NAME, PnpmWorkspace, type PnpmWorkspaceOptions, ProjectMetadata, type ProjectMetadataOptions, ROOT_CI_TASK_NAME, ROOT_TURBO_TASK_NAME, type RemoteCacheOptions, type RepositoryMetadata, ResetTask, type ResetTaskOptions, type ResolvedProjectMetadata, type SlackMetadata, type TemplateResolveResult, TestRunner, TurboRepo, type TurboRepoOptions, TurboRepoTask, type TurboRepoTaskOptions, TypeScriptConfig, TypeScriptProject, type TypeScriptProjectOptions, VERSION, VERSION_KEYS_SKIP, VERSION_NPM_PACKAGES, VSCodeConfig, type VersionKey, Vitest, type VitestConfigOptions, type VitestOptions, addApproveMergeUpgradeWorkflow, addBuildCompleteJob, awsCdkBundle, baseBundle, getLatestEligibleVersion, jestBundle, pnpmBundle, projenBundle, resolveTemplateVariables, turborepoBundle, typescriptBundle, vitestBundle };
package/lib/index.d.ts CHANGED
@@ -732,6 +732,19 @@ declare class AgentConfig extends Component {
732
732
  private resolveRules;
733
733
  private resolveSkills;
734
734
  private resolveSubAgents;
735
+ /**
736
+ * Resolves template variables in rule content using project metadata.
737
+ * Emits synthesis warnings for rules with unresolved variables.
738
+ */
739
+ private resolveTemplates;
740
+ /**
741
+ * Resolves template variables in skill instructions using project metadata.
742
+ */
743
+ private resolveSkillTemplates;
744
+ /**
745
+ * Resolves template variables in sub-agent prompts using project metadata.
746
+ */
747
+ private resolveSubAgentTemplates;
735
748
  }
736
749
 
737
750
  /**
@@ -786,6 +799,259 @@ declare const vitestBundle: AgentRuleBundle;
786
799
  */
787
800
  declare const BUILT_IN_BUNDLES: ReadonlyArray<AgentRuleBundle>;
788
801
 
802
+ /*******************************************************************************
803
+ *
804
+ * Repository Metadata
805
+ *
806
+ ******************************************************************************/
807
+ /**
808
+ * Repository identity. Required fields are auto-detected when not provided.
809
+ */
810
+ interface RepositoryMetadata {
811
+ /**
812
+ * Repository owner (GitHub user or organization).
813
+ * Auto-detected from package.json repository URL when not provided.
814
+ * @example 'codedrifters'
815
+ */
816
+ readonly owner?: string;
817
+ /**
818
+ * Repository name.
819
+ * Auto-detected from package.json repository URL when not provided.
820
+ * @example 'packages'
821
+ */
822
+ readonly name?: string;
823
+ /**
824
+ * Default branch name.
825
+ * @default 'main'
826
+ */
827
+ readonly defaultBranch?: string;
828
+ }
829
+ /*******************************************************************************
830
+ *
831
+ * GitHub Projects Metadata
832
+ *
833
+ ******************************************************************************/
834
+ /**
835
+ * A board or view within a GitHub Project.
836
+ */
837
+ interface GitHubBoardMetadata {
838
+ /** Board/view name. */
839
+ readonly name: string;
840
+ /** Board/view ID. */
841
+ readonly id?: string;
842
+ }
843
+ /**
844
+ * Sprint/iteration field metadata for GitHub Projects.
845
+ */
846
+ interface GitHubSprintMetadata {
847
+ /** Name of the iteration field in GitHub Projects. */
848
+ readonly fieldName?: string;
849
+ /** Current sprint/iteration name. */
850
+ readonly current?: string;
851
+ /** Known sprint/iteration names. */
852
+ readonly iterations?: ReadonlyArray<string>;
853
+ }
854
+ /**
855
+ * GitHub Projects (v2) context for workflow automation.
856
+ */
857
+ interface GitHubProjectMetadata {
858
+ /**
859
+ * GitHub Project name.
860
+ * @example 'CodeDrifters Packages'
861
+ */
862
+ readonly name?: string;
863
+ /**
864
+ * GitHub Project number (visible in the project URL).
865
+ * @example 3
866
+ */
867
+ readonly number?: number;
868
+ /**
869
+ * GitHub Project node ID (for GraphQL API).
870
+ * @example 'PVT_kwHOABCDEf4AGHIJ'
871
+ */
872
+ readonly nodeId?: string;
873
+ /**
874
+ * Board or view definitions within the project.
875
+ */
876
+ readonly boards?: ReadonlyArray<GitHubBoardMetadata>;
877
+ /**
878
+ * Sprint/iteration field metadata.
879
+ */
880
+ readonly sprints?: GitHubSprintMetadata;
881
+ /**
882
+ * Kanban column (status field) definitions.
883
+ * @example [{ name: 'To Do', id: 'status_1' }, { name: 'In Progress', id: 'status_2' }]
884
+ */
885
+ readonly columns?: ReadonlyArray<{
886
+ readonly name: string;
887
+ readonly id?: string;
888
+ }>;
889
+ }
890
+ /*******************************************************************************
891
+ *
892
+ * Organization Metadata
893
+ *
894
+ ******************************************************************************/
895
+ /**
896
+ * Organization or team context.
897
+ */
898
+ interface OrganizationMetadata {
899
+ /**
900
+ * Organization or team display name.
901
+ * Used in generated documentation and rule content.
902
+ * @example 'CodeDrifters'
903
+ */
904
+ readonly name?: string;
905
+ /**
906
+ * GitHub organization login (may differ from display name).
907
+ * @example 'codedrifters'
908
+ */
909
+ readonly githubOrg?: string;
910
+ }
911
+ /*******************************************************************************
912
+ *
913
+ * Slack Metadata
914
+ *
915
+ ******************************************************************************/
916
+ /**
917
+ * Slack channel references for workflow skills.
918
+ */
919
+ interface SlackMetadata {
920
+ /**
921
+ * Primary project channel.
922
+ * @example '#packages-dev'
923
+ */
924
+ readonly projectChannel?: string;
925
+ /**
926
+ * Alerts or notifications channel.
927
+ * @example '#packages-alerts'
928
+ */
929
+ readonly alertsChannel?: string;
930
+ /**
931
+ * Additional named channels. Keys are purpose identifiers.
932
+ * @example { releases: '#releases', support: '#customer-support' }
933
+ */
934
+ readonly channels?: Readonly<Record<string, string>>;
935
+ }
936
+ /*******************************************************************************
937
+ *
938
+ * Deployment Metadata
939
+ *
940
+ ******************************************************************************/
941
+ /**
942
+ * Deployment and environment hints.
943
+ */
944
+ interface DeploymentMetadata {
945
+ /**
946
+ * AWS account ID for the primary deployment target.
947
+ * @example '123456789012'
948
+ */
949
+ readonly awsAccountId?: string;
950
+ /**
951
+ * Primary AWS region.
952
+ * @example 'us-east-1'
953
+ */
954
+ readonly awsRegion?: string;
955
+ /**
956
+ * Named environments.
957
+ * @example { dev: { accountId: '111', region: 'us-east-1' }, prod: { accountId: '222', region: 'us-east-1' } }
958
+ */
959
+ readonly environments?: Readonly<Record<string, {
960
+ readonly accountId?: string;
961
+ readonly region?: string;
962
+ }>>;
963
+ }
964
+ /*******************************************************************************
965
+ *
966
+ * ProjectMetadata Options & Resolved Shape
967
+ *
968
+ ******************************************************************************/
969
+ /**
970
+ * Options for the ProjectMetadata component.
971
+ */
972
+ interface ProjectMetadataOptions {
973
+ /**
974
+ * Repository identity. When omitted, auto-detected from the Projen
975
+ * project's package.json repository field.
976
+ */
977
+ readonly repository?: RepositoryMetadata;
978
+ /**
979
+ * GitHub Projects (v2) context for workflow automation.
980
+ * Optional — only needed when skills or rules reference project boards.
981
+ */
982
+ readonly githubProject?: GitHubProjectMetadata;
983
+ /**
984
+ * Organization or team metadata.
985
+ * Optional — used in branch naming, PR conventions, and rule content.
986
+ */
987
+ readonly organization?: OrganizationMetadata;
988
+ /**
989
+ * Slack channel references for workflow skills.
990
+ * Optional — only needed when skills post to or reference Slack channels.
991
+ */
992
+ readonly slack?: SlackMetadata;
993
+ /**
994
+ * Important label names used by the project.
995
+ * Optional — allows skills and rules to reference canonical labels.
996
+ * @example ['auto-approve', 'wontfix', 'breaking-change']
997
+ */
998
+ readonly labels?: ReadonlyArray<string>;
999
+ /**
1000
+ * Milestone names or IDs for release planning.
1001
+ * Optional — allows skills to reference milestones by name.
1002
+ */
1003
+ readonly milestones?: ReadonlyArray<string>;
1004
+ /**
1005
+ * Documentation base path (relative to repo root) or external URL.
1006
+ * Optional — used by "reference docs" skills to point to the right location.
1007
+ * @example 'docs/' or 'https://docs.example.com'
1008
+ */
1009
+ readonly docsPath?: string;
1010
+ /**
1011
+ * Deployment or environment hints.
1012
+ * Optional — used by deploy-related skills or rules.
1013
+ */
1014
+ readonly deployment?: DeploymentMetadata;
1015
+ }
1016
+ /**
1017
+ * Resolved project metadata with auto-detected values filled in.
1018
+ * Consumed by AgentConfig and other configulator features at synthesis time.
1019
+ */
1020
+ interface ResolvedProjectMetadata {
1021
+ readonly repository: {
1022
+ readonly owner: string | undefined;
1023
+ readonly name: string | undefined;
1024
+ /** Always has a value (default: 'main'). */
1025
+ readonly defaultBranch: string;
1026
+ };
1027
+ readonly githubProject?: GitHubProjectMetadata;
1028
+ readonly organization?: OrganizationMetadata;
1029
+ readonly slack?: SlackMetadata;
1030
+ readonly labels?: ReadonlyArray<string>;
1031
+ readonly milestones?: ReadonlyArray<string>;
1032
+ readonly docsPath?: string;
1033
+ readonly deployment?: DeploymentMetadata;
1034
+ }
1035
+
1036
+ /**
1037
+ * Result of template variable resolution.
1038
+ */
1039
+ interface TemplateResolveResult {
1040
+ /** The template string with all variables resolved or replaced with fallbacks. */
1041
+ readonly resolved: string;
1042
+ /** Template variable keys that could not be resolved from metadata. */
1043
+ readonly unresolvedKeys: ReadonlyArray<string>;
1044
+ }
1045
+ /**
1046
+ * Resolves `{{dotted.path}}` template variables in a string using project metadata.
1047
+ * Unresolved variables are replaced with their fallback placeholders.
1048
+ *
1049
+ * @param template - String potentially containing `{{variable}}` patterns
1050
+ * @param metadata - Resolved project metadata, or undefined if not available
1051
+ * @returns The resolved string and a list of any unresolved variable keys
1052
+ */
1053
+ declare function resolveTemplateVariables(template: string, metadata: ResolvedProjectMetadata | undefined): TemplateResolveResult;
1054
+
789
1055
  /*******************************************************************************
790
1056
  *
791
1057
  * Git configs for this repo. This venn diagram has a great deal of overlap
@@ -2095,6 +2361,18 @@ interface MonorepoProjectOptions extends Omit<TypeScriptProjectOptions$1, "defau
2095
2361
  * @default true
2096
2362
  */
2097
2363
  readonly configulatorRegistryConsumer?: boolean;
2364
+ /**
2365
+ * Project metadata configuration. Provides repository identity,
2366
+ * GitHub project context, and organizational details consumed by
2367
+ * AgentConfig and other features at synthesis time.
2368
+ *
2369
+ * - `undefined` or `{}`: auto-instantiate with auto-detection (default)
2370
+ * - `ProjectMetadataOptions`: explicit metadata configuration
2371
+ * - `false`: disable ProjectMetadata entirely
2372
+ *
2373
+ * @default {} (auto-detect from package.json)
2374
+ */
2375
+ readonly projectMetadata?: ProjectMetadataOptions | false;
2098
2376
  /**
2099
2377
  * Enable AI agent configuration (Cursor, Claude Code rules).
2100
2378
  * When true, generates rule files at the monorepo root with auto-detected
@@ -2131,6 +2409,38 @@ declare class MonorepoProject extends TypeScriptAppProject {
2131
2409
  postSynthesize(): void;
2132
2410
  }
2133
2411
 
2412
+ /**
2413
+ * Provides structured project metadata consumed by AgentConfig, skills,
2414
+ * and other configulator features at synthesis time.
2415
+ *
2416
+ * This is a project-level component — it describes the project itself,
2417
+ * not any specific feature. It lives alongside MonorepoProject and
2418
+ * TypeScriptProject and is discovered by consumers via the static
2419
+ * `.of()` factory method.
2420
+ */
2421
+ declare class ProjectMetadata extends Component {
2422
+ /**
2423
+ * Returns the ProjectMetadata instance for a project, or undefined
2424
+ * if the component has not been added.
2425
+ */
2426
+ static of(project: Project): ProjectMetadata | undefined;
2427
+ /** Resolved metadata with auto-detected values filled in. */
2428
+ readonly metadata: ResolvedProjectMetadata;
2429
+ constructor(project: Project, options?: ProjectMetadataOptions);
2430
+ /**
2431
+ * Merges explicit options with auto-detected values.
2432
+ * Auto-detection reads the repository URL from package.json
2433
+ * (via Projen's NodePackage manifest) and parses GitHub owner/name.
2434
+ * Explicit options always take precedence over auto-detected values.
2435
+ */
2436
+ private resolveMetadata;
2437
+ /**
2438
+ * Attempts to auto-detect repository owner and name from the Projen
2439
+ * project's package.json repository field.
2440
+ */
2441
+ private autoDetectRepository;
2442
+ }
2443
+
2134
2444
  /**
2135
2445
  * Options for the Vitest config (test block in vitest.config).
2136
2446
  *
@@ -2379,5 +2689,5 @@ declare const COMPLETE_JOB_ID = "complete";
2379
2689
  */
2380
2690
  declare function addBuildCompleteJob(buildWorkflow: BuildWorkflow): void;
2381
2691
 
2382
- export { AGENT_MODEL, AGENT_PLATFORM, AGENT_RULE_SCOPE, AgentConfig, AwsDeployWorkflow, AwsDeploymentConfig, AwsDeploymentTarget, BUILT_IN_BUNDLES, CLAUDE_RULE_TARGET, COMPLETE_JOB_ID, JsiiFaker, MCP_TRANSPORT, MERGE_METHODS, MIMIMUM_RELEASE_AGE, MonorepoProject, PROD_DEPLOY_NAME, PnpmWorkspace, ROOT_CI_TASK_NAME, ROOT_TURBO_TASK_NAME, ResetTask, TestRunner, TurboRepo, TurboRepoTask, TypeScriptConfig, TypeScriptProject, VERSION, VERSION_KEYS_SKIP, VERSION_NPM_PACKAGES, VSCodeConfig, Vitest, addApproveMergeUpgradeWorkflow, addBuildCompleteJob, awsCdkBundle, baseBundle, getLatestEligibleVersion, jestBundle, pnpmBundle, projenBundle, turborepoBundle, typescriptBundle, vitestBundle };
2383
- export type { AgentConfigOptions, AgentModel, AgentPlatform, AgentPlatformOverrides, AgentRule, AgentRuleBundle, AgentRuleScope, AgentSkill, AgentSubAgent, AgentSubAgentPlatformOverrides, ApproveMergeUpgradeOptions, AwsAccount, AwsDeploymentTargetOptions, AwsLocalDeploymentConfig, AwsOrganization, AwsRegion, CiDeploymentConfig, ClassTypeOptions, ClaudeAutoModeConfig, ClaudeHookAction, ClaudeHookEntry, ClaudeHooksConfig, ClaudePermissionsConfig, ClaudeRuleTarget, ClaudeSandboxConfig, ClaudeSettingsConfig, CursorHookAction, CursorHooksConfig, CursorSettingsConfig, DeployWorkflowOptions, GitBranch, IDependencyResolver, McpServerConfig, McpTransport, MergeMethod, MonorepoProjectOptions, PnpmWorkspaceOptions, RemoteCacheOptions, ResetTaskOptions, TurboRepoOptions, TurboRepoTaskOptions, TypeScriptProjectOptions, VersionKey, VitestConfigOptions, VitestOptions };
2692
+ export { AGENT_MODEL, AGENT_PLATFORM, AGENT_RULE_SCOPE, AgentConfig, AwsDeployWorkflow, AwsDeploymentConfig, AwsDeploymentTarget, BUILT_IN_BUNDLES, CLAUDE_RULE_TARGET, COMPLETE_JOB_ID, JsiiFaker, MCP_TRANSPORT, MERGE_METHODS, MIMIMUM_RELEASE_AGE, MonorepoProject, PROD_DEPLOY_NAME, PnpmWorkspace, ProjectMetadata, ROOT_CI_TASK_NAME, ROOT_TURBO_TASK_NAME, ResetTask, TestRunner, TurboRepo, TurboRepoTask, TypeScriptConfig, TypeScriptProject, VERSION, VERSION_KEYS_SKIP, VERSION_NPM_PACKAGES, VSCodeConfig, Vitest, addApproveMergeUpgradeWorkflow, addBuildCompleteJob, awsCdkBundle, baseBundle, getLatestEligibleVersion, jestBundle, pnpmBundle, projenBundle, resolveTemplateVariables, turborepoBundle, typescriptBundle, vitestBundle };
2693
+ export type { AgentConfigOptions, AgentModel, AgentPlatform, AgentPlatformOverrides, AgentRule, AgentRuleBundle, AgentRuleScope, AgentSkill, AgentSubAgent, AgentSubAgentPlatformOverrides, ApproveMergeUpgradeOptions, AwsAccount, AwsDeploymentTargetOptions, AwsLocalDeploymentConfig, AwsOrganization, AwsRegion, CiDeploymentConfig, ClassTypeOptions, ClaudeAutoModeConfig, ClaudeHookAction, ClaudeHookEntry, ClaudeHooksConfig, ClaudePermissionsConfig, ClaudeRuleTarget, ClaudeSandboxConfig, ClaudeSettingsConfig, CursorHookAction, CursorHooksConfig, CursorSettingsConfig, DeployWorkflowOptions, DeploymentMetadata, GitBranch, GitHubBoardMetadata, GitHubProjectMetadata, GitHubSprintMetadata, IDependencyResolver, McpServerConfig, McpTransport, MergeMethod, MonorepoProjectOptions, OrganizationMetadata, PnpmWorkspaceOptions, ProjectMetadataOptions, RemoteCacheOptions, RepositoryMetadata, ResetTaskOptions, ResolvedProjectMetadata, SlackMetadata, TemplateResolveResult, TurboRepoOptions, TurboRepoTaskOptions, TypeScriptProjectOptions, VersionKey, VitestConfigOptions, VitestOptions };