1. Packages
  2. Packages
  3. Gitlab Provider
  4. API Docs
  5. getSystemHook
Viewing docs for GitLab v10.0.0
published on Friday, Jun 26, 2026 by Pulumi
gitlab logo
Viewing docs for GitLab v10.0.0
published on Friday, Jun 26, 2026 by Pulumi

    The gitlab.SystemHook data source allows to retrieve details about a system hook.

    This data source requires administrator privileges.

    Upstream API: GitLab REST API docs

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as gitlab from "@pulumi/gitlab";
    
    const example = gitlab.getSystemHook({
        hookId: 1,
    });
    
    import pulumi
    import pulumi_gitlab as gitlab
    
    example = gitlab.get_system_hook(hook_id=1)
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-gitlab/sdk/v10/go/gitlab"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := gitlab.GetSystemHook(ctx, &gitlab.LookupSystemHookArgs{
    			HookId: 1,
    		}, nil)
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using GitLab = Pulumi.GitLab;
    
    return await Deployment.RunAsync(() => 
    {
        var example = GitLab.GetSystemHook.Invoke(new()
        {
            HookId = 1,
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.gitlab.GitlabFunctions;
    import com.pulumi.gitlab.inputs.GetSystemHookArgs;
    import java.util.ArrayList;
    import java.util.Arrays;
    import java.util.Map;
    import java.io.File;
    import java.nio.file.Files;
    import java.nio.file.Paths;
    
    public class App {
        public static void main(String[] args) {
            Pulumi.run(App::stack);
        }
    
        public static void stack(Context ctx) {
            final var example = GitlabFunctions.getSystemHook(GetSystemHookArgs.builder()
                .hookId(1)
                .build());
    
        }
    }
    
    variables:
      example:
        fn::invoke:
          function: gitlab:getSystemHook
          arguments:
            hookId: 1
    
    pulumi {
      required_providers {
        gitlab = {
          source = "pulumi/gitlab"
        }
      }
    }
    
    data "gitlab_getsystemhook" "example" {
      hook_id = 1
    }
    

    Using getSystemHook

    Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.

    function getSystemHook(args: GetSystemHookArgs, opts?: InvokeOptions): Promise<GetSystemHookResult>
    function getSystemHookOutput(args: GetSystemHookOutputArgs, opts?: InvokeOptions): Output<GetSystemHookResult>
    def get_system_hook(hook_id: Optional[int] = None,
                        opts: Optional[InvokeOptions] = None) -> GetSystemHookResult
    def get_system_hook_output(hook_id: pulumi.Input[Optional[int]] = None,
                        opts: Optional[InvokeOptions] = None) -> Output[GetSystemHookResult]
    func LookupSystemHook(ctx *Context, args *LookupSystemHookArgs, opts ...InvokeOption) (*LookupSystemHookResult, error)
    func LookupSystemHookOutput(ctx *Context, args *LookupSystemHookOutputArgs, opts ...InvokeOption) LookupSystemHookResultOutput

    > Note: This function is named LookupSystemHook in the Go SDK.

    public static class GetSystemHook 
    {
        public static Task<GetSystemHookResult> InvokeAsync(GetSystemHookArgs args, InvokeOptions? opts = null)
        public static Output<GetSystemHookResult> Invoke(GetSystemHookInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetSystemHookResult> getSystemHook(GetSystemHookArgs args, InvokeOptions options)
    public static Output<GetSystemHookResult> getSystemHook(GetSystemHookArgs args, InvokeOptions options)
    
    fn::invoke:
      function: gitlab:index/getSystemHook:getSystemHook
      arguments:
        # arguments dictionary
    data "gitlab_getsystemhook" "name" {
        # arguments
    }

    The following arguments are supported:

    HookId int
    The id of the system hook.
    HookId int
    The id of the system hook.
    hook_id number
    The id of the system hook.
    hookId Integer
    The id of the system hook.
    hookId number
    The id of the system hook.
    hook_id int
    The id of the system hook.
    hookId Number
    The id of the system hook.

    getSystemHook Result

    The following output properties are available:

    CreatedAt string
    The date and time the hook was created in ISO8601 format.
    Description string
    The description of the hook.
    EnableSslVerification bool
    Do SSL verification when triggering the hook.
    HookId int
    The id of the system hook.
    Id string
    The ID of this data source. In the format <hook_id>.
    MergeRequestsEvents bool
    Trigger hook on merge requests events.
    Name string
    The name of the hook.
    PushEvents bool
    When true, the hook fires on push events.
    RepositoryUpdateEvents bool
    Trigger hook on repository update events.
    SigningTokenPresent bool
    Whether a signingToken is configured server-side. Reflects the value returned by the GitLab API.
    TagPushEvents bool
    When true, the hook fires on new tags being pushed.
    Url string
    The hook URL.
    CreatedAt string
    The date and time the hook was created in ISO8601 format.
    Description string
    The description of the hook.
    EnableSslVerification bool
    Do SSL verification when triggering the hook.
    HookId int
    The id of the system hook.
    Id string
    The ID of this data source. In the format <hook_id>.
    MergeRequestsEvents bool
    Trigger hook on merge requests events.
    Name string
    The name of the hook.
    PushEvents bool
    When true, the hook fires on push events.
    RepositoryUpdateEvents bool
    Trigger hook on repository update events.
    SigningTokenPresent bool
    Whether a signingToken is configured server-side. Reflects the value returned by the GitLab API.
    TagPushEvents bool
    When true, the hook fires on new tags being pushed.
    Url string
    The hook URL.
    created_at string
    The date and time the hook was created in ISO8601 format.
    description string
    The description of the hook.
    enable_ssl_verification bool
    Do SSL verification when triggering the hook.
    hook_id number
    The id of the system hook.
    id string
    The ID of this data source. In the format <hook_id>.
    merge_requests_events bool
    Trigger hook on merge requests events.
    name string
    The name of the hook.
    push_events bool
    When true, the hook fires on push events.
    repository_update_events bool
    Trigger hook on repository update events.
    signing_token_present bool
    Whether a signingToken is configured server-side. Reflects the value returned by the GitLab API.
    tag_push_events bool
    When true, the hook fires on new tags being pushed.
    url string
    The hook URL.
    createdAt String
    The date and time the hook was created in ISO8601 format.
    description String
    The description of the hook.
    enableSslVerification Boolean
    Do SSL verification when triggering the hook.
    hookId Integer
    The id of the system hook.
    id String
    The ID of this data source. In the format <hook_id>.
    mergeRequestsEvents Boolean
    Trigger hook on merge requests events.
    name String
    The name of the hook.
    pushEvents Boolean
    When true, the hook fires on push events.
    repositoryUpdateEvents Boolean
    Trigger hook on repository update events.
    signingTokenPresent Boolean
    Whether a signingToken is configured server-side. Reflects the value returned by the GitLab API.
    tagPushEvents Boolean
    When true, the hook fires on new tags being pushed.
    url String
    The hook URL.
    createdAt string
    The date and time the hook was created in ISO8601 format.
    description string
    The description of the hook.
    enableSslVerification boolean
    Do SSL verification when triggering the hook.
    hookId number
    The id of the system hook.
    id string
    The ID of this data source. In the format <hook_id>.
    mergeRequestsEvents boolean
    Trigger hook on merge requests events.
    name string
    The name of the hook.
    pushEvents boolean
    When true, the hook fires on push events.
    repositoryUpdateEvents boolean
    Trigger hook on repository update events.
    signingTokenPresent boolean
    Whether a signingToken is configured server-side. Reflects the value returned by the GitLab API.
    tagPushEvents boolean
    When true, the hook fires on new tags being pushed.
    url string
    The hook URL.
    created_at str
    The date and time the hook was created in ISO8601 format.
    description str
    The description of the hook.
    enable_ssl_verification bool
    Do SSL verification when triggering the hook.
    hook_id int
    The id of the system hook.
    id str
    The ID of this data source. In the format <hook_id>.
    merge_requests_events bool
    Trigger hook on merge requests events.
    name str
    The name of the hook.
    push_events bool
    When true, the hook fires on push events.
    repository_update_events bool
    Trigger hook on repository update events.
    signing_token_present bool
    Whether a signingToken is configured server-side. Reflects the value returned by the GitLab API.
    tag_push_events bool
    When true, the hook fires on new tags being pushed.
    url str
    The hook URL.
    createdAt String
    The date and time the hook was created in ISO8601 format.
    description String
    The description of the hook.
    enableSslVerification Boolean
    Do SSL verification when triggering the hook.
    hookId Number
    The id of the system hook.
    id String
    The ID of this data source. In the format <hook_id>.
    mergeRequestsEvents Boolean
    Trigger hook on merge requests events.
    name String
    The name of the hook.
    pushEvents Boolean
    When true, the hook fires on push events.
    repositoryUpdateEvents Boolean
    Trigger hook on repository update events.
    signingTokenPresent Boolean
    Whether a signingToken is configured server-side. Reflects the value returned by the GitLab API.
    tagPushEvents Boolean
    When true, the hook fires on new tags being pushed.
    url String
    The hook URL.

    Package Details

    Repository
    GitLab pulumi/pulumi-gitlab
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the gitlab Terraform Provider.
    gitlab logo
    Viewing docs for GitLab v10.0.0
    published on Friday, Jun 26, 2026 by Pulumi

      Try Pulumi Cloud free.
      Your team will thank you.

      Start free trial