Showing results for 
Search instead for 
Did you mean: 

Error processing request: E00007 - User authentication failed due to invalid authentication values


I am a newbie here so please forgive me if  I make any mistakes in adhering to the rules of this forum.

The issue i am facing is :


"Error processing request: E00007 - User authentication failed due to invalid authentication values"


I am using a proper value of API Login Id and Transaction key. 

But I get this auth error.

Code sample provided below:


using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using AuthorizeNet;

namespace SampleReporting
class Program
static void Main(string[] args)

var gate = new ReportingGateway("MY API ", "MY Transaction Key");

//Get all the batches settled
var batches = gate.GetSettledBatchList(); //<--- The code fails here

Console.WriteLine("All Batches in the last 30 days");
foreach (var item in batches)
Console.WriteLine("Batch ID: {0}, Settled On : {1}", item.ID, item.SettledOn.ToShortDateString());


var transactions = gate.GetTransactionList();
foreach (var item in transactions)
Console.WriteLine("Transaction {0}: Card: {1} for {2} on {3}", item.TransactionID, item.CardNumber, item.SettleAmount.ToString("C"), item.DateSubmitted.ToShortDateString());




I am using Visula Studio and creating a console application in C# for the above code.

I have also referenced the AuthorizeNet.dll in my solution.

Any help will be highly appreciated.


Thanks in Advance!!!




The error seems to be due to the fact that the Gateway is pointing to the test site and I am using production credentials.


URL ""


At runtime its is taking the value from the TEST_URL. 

Any ideas on how to make the gateway point to the Prod url as the value of the ServiceURL?



var gate = new ReportingGateway("MY API ", "MY Transaction Key");


var gate = new ReportingGateway("MY API ", "MY Transaction Key", ServiceMode.Live);


Many many Thanks  for the reply RaynorC1emen7.!!


Now it is taking the prod URL for the connecting to the gateway. But the error still persists.

"Error processing request: E00007 - User authentication failed due to invalid authentication values."


Is there a way to check if the API Login ID and Transaction Key are consistent? I have no other creds but these.


Thanks in Advance!!!

Both are case sensitive, and make sure there is no spaces.

You can login to the account - settings to see the API login id. The transactionKey is not viewable, but you can regenerate it at the account settings.

I get this usually when I'm processing a CIM transaction and passing an ID generated within the Sandbox to the Live API key values. 

We have tested making a $2 payment using a live Card but we face the below issue.
[code:net\authorize\api\contract\v1\MessagesType\MessageAType:private] => E00007
[text:net\authorize\api\contract\v1\MessagesType\MessageAType:private] => User authentication failed due to invalid authentication values.
We are using the SDK from Authorize.Net and not using the API endpoint.
We are using the below script :

	// Common setup for API credentials  
	  $merchantAuthentication = new AnetAPI\MerchantAuthenticationType();   
	  $refId = 'ref' . time();

	// Create the payment object for a payment nonce
	  $opaqueData = new AnetAPI\OpaqueDataType();
	  //   $creditCard->setCardNumber("4111111111111111");  
	  //   $creditCard->setExpirationDate( "2038-12");
	  //   $creditCard->setCardCode("123");
	// Add the payment data to a paymentType object
	  $paymentOne = new AnetAPI\PaymentType();
	  //   $paymentOne = new AnetAPI\PaymentType();
	  //   $paymentOne->setCreditCard($creditCard);

	// Create order information
	  $order = new AnetAPI\OrderType();
	  // $order->setInvoiceNumber("10101");
	  $order->setDescription("Trip for ".$_SESSION["tour"]);

	// Set the customer's Bill To address
	  $customerAddress = new AnetAPI\CustomerAddressType();

	// Set the customer's identifying information
	  $customerData = new AnetAPI\CustomerDataType();

	// Add values for transaction settings
	  $duplicateWindowSetting = new AnetAPI\SettingType();

	// Add some merchant defined fields. These fields won't be stored with the transaction,
	// but will be echoed back in the response.
	  $merchantDefinedField1 = new AnetAPI\UserFieldType();

	  $merchantDefinedField2 = new AnetAPI\UserFieldType();

	  // Create a transaction
	  $transactionRequestType = new AnetAPI\TransactionRequestType();
	  $request = new AnetAPI\CreateTransactionRequest();
	  $request->setRefId( $refId);
	  $controller = new AnetController\CreateTransactionController($request);
	  $response = $controller->executeWithApiResponse(\net\authorize\api\constants\ANetEnvironment::SANDBOX);