광고주 신원 확인

사용자에게 안전하고 신뢰할 수 있는 광고 생태계를 제공하고 새로운 규정을 준수하기 위해 Google에서는 광고주가 하나 이상의 인증 프로그램을 완료하도록 요구합니다.

인증 프로그램을 완료해야 하는 경우 인증 절차에 기한이 설정될 수 있습니다. 기한이 지나도 인증을 완료하지 않으면 계정이 일시중지될 수 있습니다.

요구하지 않아도 선제적으로 인증을 받을 수도 있습니다. IdentityVerificationService는 다음을 실행하는 메서드를 제공합니다.

  • 기한을 포함하여 고객 계정의 인증 절차 상태를 가져옵니다.
  • 인증 절차 시작

인증 상태 가져오기

고객 계정의 광고주 신원 확인 절차 상태를 검색하려면 GetIdentityVerification 메서드를 호출합니다.

자바

private IdentityVerification getIdentityVerification(
    long customerId, IdentityVerificationServiceClient identityVerificationServiceClient) {
  GetIdentityVerificationResponse response =
      identityVerificationServiceClient.getIdentityVerification(Long.toString(customerId));
  if (response.getIdentityVerificationCount() == 0) {
    return null;
  }
  IdentityVerification identityVerification = response.getIdentityVerification(0);
  String deadline =
      identityVerification
          .getIdentityVerificationRequirement()
          .getVerificationCompletionDeadlineTime();
  IdentityVerificationProgress progress = identityVerification.getVerificationProgress();
  System.out.printf(
      "Account %d has a verification completion deadline of '%s' and status '%s' for advertiser"
          + " identity verification.%n",
      customerId, deadline, progress.getProgramStatus());
  return identityVerification;
}

      

C#

private static IdentityVerification GetIdentityVerification(
        GoogleAdsClient client, long customerId)
{
    IdentityVerificationServiceClient identityVerificationService =
        client.GetService(Services.V18.IdentityVerificationService);

    try {
        GetIdentityVerificationResponse response =
            identityVerificationService.GetIdentityVerification(
                new GetIdentityVerificationRequest()
                {
                    CustomerId = customerId.ToString()
                }
            );

            if (response.IdentityVerification.Count == 0)
            {
                return null;
            }

            IdentityVerification identityVerification = response.IdentityVerification[0];
            string deadline =
                identityVerification.IdentityVerificationRequirement.VerificationCompletionDeadlineTime;
             IdentityVerificationProgress identityVerificationProgress =
                identityVerification.VerificationProgress;
            Console.WriteLine($"Account {customerId} has a verification completion " +
                $"deadline of {deadline} and status " +
                $"{identityVerificationProgress.ProgramStatus} for advertiser identity " +
                "verification.");

            return identityVerification;
    } catch (GoogleAdsException e)
    {
        Console.WriteLine("Failure:");
        Console.WriteLine($"Message: {e.Message}");
        Console.WriteLine($"Failure: {e.Failure}");
        Console.WriteLine($"Request ID: {e.RequestId}");
        throw;
    }


}
      

PHP

private static function getIdentityVerification(
    int $customerId,
    IdentityVerificationServiceClient $identityVerificationServiceClient
) {
    // Gets an identity verification response.
    $response = $identityVerificationServiceClient->getIdentityVerification(
        GetIdentityVerificationRequest::build($customerId)
    );
    if (empty($response->getIdentityVerification())) {
        return null;
    }

    // Prints some details about the retrieved identity verification.
    /** @var IdentityVerification $identityVerification */
    $identityVerification = $response->getIdentityVerification()->getIterator()->current();
    $deadline = $identityVerification->getIdentityVerificationRequirement()
        ->getVerificationCompletionDeadlineTime();
    $progress = $identityVerification->getVerificationProgress();
    printf(
        "Account %d has a verification completion deadline of '%s' and status '%s' for"
        . " advertiser identity verification.%s",
        $customerId,
        $deadline,
        IdentityVerificationProgramStatus::name($progress->getProgramStatus()),
        PHP_EOL
    );

    return $identityVerification;
}
      

Python

def get_identity_verification(client, customer_id):
    """Retrieves the status of the advertiser identity verification process.

    Args:
        client: An initialized GoogleAdsClient instance.
        customer_id: The client customer ID str.

    Returns:
        either an IdentityVerification instance, or None
    """
    service = client.get_service("IdentityVerificationService")
    response = service.get_identity_verification(customer_id=customer_id)

    # Check if the response contains any indentity verifications. If not, then
    # None will be returned.
    if response.identity_verification:
        identity_verification = response.identity_verification[0]
        deadline = (
            identity_verification.identity_verification_requirement.verification_completion_deadline_time
        )
        progress = identity_verification.verification_progress.program_status

        print(
            f"Account {customer_id} has a verification completion deadline "
            f"of {deadline} and status {progress} for advertiser identity "
            "verification."
        )

        return identity_verification
      

Ruby

def get_identity_verification(client, customer_id)
  response = client.service.identity_verification.get_identity_verification(
    customer_id: customer_id
  )

  return nil if response.nil? || response.identity_verification.empty?

  identity_verification = response.identity_verification.first
  deadline = identity_verification.
    identity_verification_requirement.
    verification_completion_deadline_time
  progress = identity_verification.verification_progress
  puts "Account #{customer_id} has a verification completion deadline " \
    "of #{deadline} and status #{progress.program_status} for advertiser " \
    "identity verification."

  identity_verification
end
      

Perl

sub get_identity_verification {
  my ($api_client, $customer_id) = @_;

  my $response = $api_client->IdentityVerificationService()->get({
    customerId => $customer_id
  });

  if (!defined $response->{identityVerification}) {
    printf "Account %s does not require advertiser identity verification.",
      $customer_id;
    return;
  }

  my $identity_verification = $response->{identityVerification}[0];
  my $deadline = $identity_verification->{identityVerificationRequirement}
    {verificationCompletionDeadlineTime};
  my $identity_verification_progress =
    $identity_verification->{verificationProgress};

  printf "Account %s has a verification completion deadline of %s and status " .
    "%s for advertiser identity verification.", $customer_id, $deadline,
    $identity_verification_progress->{programStatus};
  return $identity_verification;
}
      

고객 계정이 필수 광고주 ID 인증 프로그램에 등록된 경우 서비스는 IdentityVerification 객체 목록이 포함된 비어 있지 않은 응답을 반환합니다. 빈 응답은 고객 계정에 광고주 신원 확인이 필요하지 않다는 것을 나타냅니다.

Google Ads API는 ADVERTISER_IDENTITY_VERIFICATION 프로그램만 지원하므로 목록에 이 프로그램만 표시됩니다.

IdentityVerification 객체에는 다음 속성이 포함되어 있습니다.

확인 절차 시작

고객 계정이 필수 광고주 신원 확인 프로그램에 등록되어 있고 GetIdentityVerification가 인증 절차 완료 기한이 포함된 비어 있지 않은 응답을 반환한 경우 StartIdentityVerification를 호출하여 인증 세션을 시작할 수 있습니다.

자바

private void startIdentityVerification(
    long customerId, IdentityVerificationServiceClient identityVerificationServiceClient) {
  // Sends a request to start the identity verification process.
  identityVerificationServiceClient.startIdentityVerification(
      Long.toString(customerId), IdentityVerificationProgram.ADVERTISER_IDENTITY_VERIFICATION);
}
      

C#

private static void StartIdentityVerification(GoogleAdsClient client, long customerId)
{
    IdentityVerificationServiceClient identityVerificationService =
        client.GetService(Services.V18.IdentityVerificationService);

    StartIdentityVerificationRequest request = new StartIdentityVerificationRequest()
    {
        CustomerId = customerId.ToString(),
        VerificationProgram = IdentityVerificationProgram.AdvertiserIdentityVerification
    };

    try {
        identityVerificationService.StartIdentityVerification(request);
    } catch (GoogleAdsException e)
    {
        Console.WriteLine("Failure:");
        Console.WriteLine($"Message: {e.Message}");
        Console.WriteLine($"Failure: {e.Failure}");
        Console.WriteLine($"Request ID: {e.RequestId}");
        throw;
    }
}
      

PHP

private static function startIdentityVerification(
    int $customerId,
    IdentityVerificationServiceClient $identityVerificationServiceClient
): void {
    // Sends a request to start the identity verification process.
    $identityVerificationServiceClient->startIdentityVerification(
        StartIdentityVerificationRequest::build(
            $customerId,
            IdentityVerificationProgram::ADVERTISER_IDENTITY_VERIFICATION
        )
    );
}
      

Python

def start_identity_verification(client, customer_id):
    """Starts the identity verification process.

    Args:
        client: An initialized GoogleAdsClient instance.
        customer_id: The client customer ID str.
    """
    service = client.get_service("IdentityVerificationService")
    # Sends a request to start the identity verification process.
    service.start_identity_verification(
        customer_id=customer_id,
        verification_program=client.enums.IdentityVerificationProgramEnum.ADVERTISER_IDENTITY_VERIFICATION,
    )
      

Ruby

def start_identity_verification(client, customer_id)
  client.service.identity_verification.start_identity_verification(
    customer_id: customer_id,
    verification_program: :ADVERTISER_IDENTITY_VERIFICATION,
  )
end
      

Perl

sub start_identity_verification {
  my ($api_client, $customer_id) = @_;

  my $request =
    Google::Ads::GoogleAds::V18::Services::IdentityVerificationService::StartIdentityVerificationRequest
    ->new({
      customerId          => $customer_id,
      verificationProgram => ADVERTISER_IDENTITY_VERIFICATION
    });

  $api_client->AdvertiserIdentityVerificationService()
    ->start_identity_verification($request);
}
      

진행 중인 다른 인증 세션이 없는 경우에만 성공합니다. 인증 세션을 시작한 후에는 후속 GetIdentityVerification 호출이 사용자가 인증 절차를 완료할 수 있는 작업 URL과 작업 URL의 만료 시간을 반환합니다.

만료 시간이 지나면 StartIdentityVerification를 다시 호출하여 새 인증 세션을 시작할 수 있습니다.