> For the complete documentation index, see [llms.txt](https://developer.harness.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://developer.harness.io/infrastructure-as-code-management/iacm-api-reference/module-registry/list-module-by-id.md).

# List module by id

List a module from the module registry by ID

```json
{"openapi":"3.0.3","info":{"title":"Infrastructure as Code Management","version":"0.1.0"},"tags":[{"name":"module-registry","description":"The module-registry service is a private registry for Terraform/Opentofu modules"}],"servers":[{"url":"http://localhost:80"}],"paths":{"/api/modules/{id}":{"get":{"tags":["module-registry"],"summary":"List module by id","description":"List a module from the module registry by ID","operationId":"module-registry#list-modules-by-id","parameters":[{"name":"scope_org","in":"query","description":"org name","allowEmptyValue":true,"schema":{"type":"string","description":"org name"}},{"name":"scope_project","in":"query","description":"project name","allowEmptyValue":true,"schema":{"type":"string","description":"project name"}},{"name":"id","in":"path","description":"module id","required":true,"schema":{"type":"string","description":"module id"}},{"name":"Harness-Account","in":"header","description":"account name","allowEmptyValue":true,"required":true,"schema":{"type":"string","description":"account name"}}],"responses":{"200":{"description":"OK response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListModuleByIDResponse"}}}},"400":{"description":"BadRequestError: Bad Request response.","content":{"application/vnd.goa.error":{"schema":{"$ref":"#/components/schemas/RegistryError"}}}},"401":{"description":"UnauthorizedError: Unauthorized response.","content":{"application/vnd.goa.error":{"schema":{"$ref":"#/components/schemas/RegistryError"}}}},"403":{"description":"ForbiddenError: Forbidden response.","content":{"application/vnd.goa.error":{"schema":{"$ref":"#/components/schemas/RegistryError"}}}},"404":{"description":"NotFoundError: Not Found response.","content":{"application/vnd.goa.error":{"schema":{"$ref":"#/components/schemas/RegistryError"}}}},"408":{"description":"TimeoutError: Request Timeout response.","content":{"application/vnd.goa.error":{"schema":{"$ref":"#/components/schemas/RegistryError"}}}},"409":{"description":"ConflictError: Conflict response.","content":{"application/vnd.goa.error":{"schema":{"$ref":"#/components/schemas/RegistryError"}}}},"423":{"description":"LockedError: Locked response.","content":{"application/vnd.goa.error":{"schema":{"$ref":"#/components/schemas/RegistryError"}}}},"499":{"description":"ContextCancelledError:  response.","content":{"application/vnd.goa.error":{"schema":{"$ref":"#/components/schemas/RegistryError"}}}},"500":{"description":"InternalServerError: Internal Server Error response.","content":{"application/vnd.goa.error":{"schema":{"$ref":"#/components/schemas/RegistryError"}}}},"502":{"description":"BadGatewayError: Bad Gateway response.","content":{"application/vnd.goa.error":{"schema":{"$ref":"#/components/schemas/RegistryError"}}}}}}}},"components":{"schemas":{"ListModuleByIDResponse":{"type":"object","properties":{"account":{"type":"string","description":"Harness account ID that owns the module.","minLength":1,"maxLength":128},"created":{"type":"integer","description":"Created is the unix timestamp at which the resource was originally created in milliseconds.","format":"int64"},"description":{"type":"string","description":"Free-form text describing the purpose and usage of the module."},"domain_prefix":{"type":"string","description":"Domain prefix for the module"},"git_tag_style":{"type":"string","description":"Pattern used to match Git tags for module versioning. Use 'module-name-*' to match tags like 'my-vpc-module-v1.0.0'."},"id":{"type":"string","description":"module id"},"module_error":{"type":"string","description":"error while retrieving the module"},"name":{"type":"string","description":"Human-readable name of the module. Must be unique within the same scope and system.","minLength":1,"maxLength":128},"namespace":{"type":"string","description":"Namespace derived from account, org and project for use with the Terraform module registry"},"onboarding_pipeline":{"type":"string","description":"Identifier of the Harness pipeline used for module onboarding and metadata sync."},"onboarding_pipeline_org":{"type":"string","description":"Organization where the onboarding pipeline is defined. Defaults to scope_org if not provided."},"onboarding_pipeline_project":{"type":"string","description":"Project where the onboarding pipeline is defined. Defaults to scope_project if not provided."},"onboarding_pipeline_sync":{"type":"boolean","description":"When true, module metadata is automatically synced via the onboarding pipeline when new Git tags are pushed.","default":false},"onboarding_pipeline_wh":{"type":"string","description":"Webhook identifier used to trigger the onboarding pipeline on Git events.","default":""},"org":{"type":"string","description":"Organization identifier where the Git connector is defined. Defaults to scope_org if not provided.","maxLength":1024},"project":{"type":"string","description":"Project identifier where the Git connector is defined. Defaults to scope_project if not provided.","maxLength":1024},"repository":{"type":"string","description":"Name of the Git repository that contains the module source code."},"repository_branch":{"type":"string","description":"Repository Branch in which the code should be accessed."},"repository_commit":{"type":"string","description":"Repository Commit/Tag in which the code should be accessed."},"repository_connector":{"type":"string","description":"Harness Git connector identifier used to access the Git repository. Must reference a valid Git connector in your account. Leave empty when using Harness Code as the repository source."},"repository_path":{"type":"string","description":"Repository Path is the path in which the infra code resides.","default":""},"repository_url":{"type":"string","description":"Repository url."},"scope_org":{"type":"string","description":"Organization identifier where the module is scoped.","maxLength":1024},"scope_project":{"type":"string","description":"Project identifier where the module is scoped.","maxLength":1024},"storage_type":{"type":"string","description":"Defines how module versions are stored. 'git_reference' resolves versions from Git tags; 'artifact' stores uploaded archive files.","default":"git_reference","enum":["git_reference","artifact"]},"synced":{"type":"integer","description":"Synced is the unix timestamp at which the resource was synced for the last time in milliseconds.","format":"int64"},"system":{"type":"string","description":"Provider or system the module targets. Lowercase letters only (e.g. aws, gcp, azure, kubernetes).","pattern":"^[a-z]+$","minLength":1,"maxLength":128},"tags":{"type":"string","description":"Comma-separated list of tags to categorize the module (e.g. networking,vpc,aws)."},"testing_enabled":{"type":"boolean","description":"testing enabled"},"testing_metadata":{"$ref":"#/components/schemas/HarnessIacmModuleRegistryModuleTestingMetadata"},"updated":{"type":"integer","description":"Modified is the unix timestamp at which the resource was last modified in milliseconds.","format":"int64"},"version_statuses":{"type":"object","description":"Map of module version to lifecycle status (supported, warning, deprecated). Populated only when the lifecycle feature flag is enabled.","additionalProperties":{"type":"string"}},"versions":{"type":"array","items":{"type":"string"},"description":"versions"}},"required":["account","name","system","id","created","updated","synced"]},"HarnessIacmModuleRegistryModuleTestingMetadata":{"type":"object","properties":{"account":{"type":"string","description":"Account is the internal customer account ID.","minLength":1,"maxLength":128},"org":{"type":"string","description":"Org is the organisation identifier.","minLength":1,"maxLength":128},"pipelines":{"type":"array","items":{"type":"string"},"description":"pipelines where the testing is enabled"},"project":{"type":"string","description":"Project is the project identifier.","minLength":1,"maxLength":128},"provider_connector":{"type":"string","description":"provider connector for testing purposes"},"provisioner_type":{"type":"string","description":"provisioner type for testing purposes"},"provisioner_version":{"type":"string","description":"provisioner version for testing purposes"},"release_pipeline":{"type":"string","description":"release pipeline"}},"required":["account","org","project","provisioner_type","provisioner_version","provider_connector","pipelines"]},"RegistryError":{"type":"object","properties":{"fault":{"type":"boolean","description":"Is the error a server-side fault?"},"id":{"type":"string","description":"ID is a unique identifier for this particular occurrence of the problem."},"message":{"type":"string","description":"Message is a human-readable explanation specific to this occurrence of the problem."},"name":{"type":"string","description":"Name is the name of this class of errors."},"temporary":{"type":"boolean","description":"Is the error temporary?"},"timeout":{"type":"boolean","description":"Is the error a timeout?"}},"required":["name","id","message","temporary","timeout","fault"]}}}}
```
