Anaplan Connect import error 12476




I am currently having issues with my script using Anaplan connect and I hope someone could help me with this.

The error I receive is: 

ERROR 12476 |--   Imports not found: Imports not found for Model-ID=8954E749858F4CEEB35EBD5BFB54595B

(Feign: status 401 reading AnaplanAPI#getImports(String,String,int); content:{"status":{"code":401,"message":"Not Authenticated."}})E:\GMS_Anaplan\anaplan-connect-1-4-2>”


I already  checked the “obvious” things: model id matches, import action name and file name are correct.

Would you be able to advise me on:

  1. Did the script actually passed the authentication phase? In the run logs that is the log just before the error code on the import (see attached)
  2. Do you see a mistake in the script? (see below)
  3. Could this error be related to the file option default file? currently I have set this to "Everyone'.

Thank you for your help!





REM @Echo off
rem For details of how to configure this script see doc\Anaplan Connect User Guide.doc
REM ###########################
set CertPath="E:\GMS_Anaplan\anaplan-connect-1-4-2\certs\AnaplanGMSCertPublickey.pem"
set PrivateKey="E:\GMS_Anaplan\anaplan-connect-1-4-2\certs\AnaplanGMSCertPrivatekey.pem:"
set WorkspaceId="8a81b09e603d355d016149ba8d6e67ce"
set ModelId="8954E749858F4CEEB35EBD5BFB54595B"
set JAVA_HOME=E:\GMS_Anaplan\jre1.8.0_144
set ServiceUrl=""
set AuthUrl=""
set Chunksize=40
set FileName = "MOS_Actuals_BU_Rate.csv"
set FilePath ="E:\GMS_Anaplan\UploadtoAnaplan\MOS_Actuals_BU_Rate.csv"
set DumpName ="E:\GMS_Anaplan\UploadtoAnaplanMOS_Actuals_BU_Rate_Error.txt"
rem set Operation=-certificate "E:\GMS_Anaplan\anaplan-connect-1-4-2\DevCerts\" -export "Export_APO_AOP New" -execute -get "E:\ANAplan_APO\APO_Data\AOP\Export_APO_AOP.txt"
rem *** End of settings - Do not edit below this line ***
set Operation=-debug -service %ServiceUrl% -auth %AuthUrl% -workspace %WorkspaceId% -model %ModelId% -chunksize %Chunksize% -file %FileName% -put %FilePath% -import "2. Upload HFM Actuals at Budget Rate from file" -execute -output %DumpName%
set Credentials=-certificate %CertPath% -pkey %PrivateKey%
setlocal enableextensions enabledelayedexpansion || exit /b 1
cd %~dp0
REM set Command=.\AnaplanClient.bat %Credentials% -workspace %WorkspaceId% -model %ModelId% %Operation%
set Command=.\AnaplanClient.bat %Credentials% -service %ServiceUrl% -auth %AuthUrl% -workspace %WorkspaceId% -model %ModelId% -chunksize %Chunksize% -file %FileName% -put %FilePath% -import "2. Upload HFM Actuals at Budget Rate from file" -execute -output %DumpName%

@Echo %Command%
cmd /c %Command%

Best Answer

  • LouiseBourgonjon_*46808

    we were able to solve the issue.

    The root cause for the issue is that the service account which is associated to the certificate was not activated yet. After receiving the activation email and setting a password, the script ran successfully!


    @DaanishSoomar  thank you for your contribution to finding solutions for this issue!


  • Hi @LouiseBourgonjon 

     your script has not passed authentication but script looks all good, check if your network has whitelisted and Also, The option which you selected 'everyone' is also correct, I recommend checking that the user role have permission to the action you are trying to run.



  • Looks like you have a trailing colon at the end of your private key path?

  • Hi Abhay,


    Thank you for your input.

    We are already using a similar script with urls to connect to another anaplan workspace, so the urls are whitelisted.

    I also checked the permissions and user access rights, but it seems that the service account we use in the connection has all access rights needed. However, the checkbox "Workspace admin" is not checked for the service user. Is that necessary?

  • Hi Ben,


    We need to add that trailing colon otherwise we run into another error: 

    E:\GMS_Anaplan\anaplan-connect-1-4-2>cmd /c .\AnaplanClient.bat -certificate "E:\GMS_Anaplan\anaplan-connect-1-4-2\certs

    \AnaplanGMSCertPublickey.pem" -pkey "E:\GMS_Anaplan\anaplan-connect-1-4-2\certs\AnaplanGMSCertPrivatekey.pem" -service "" -auth -workspace "8a81b09e603d355d016149ba8d6e67ce" -model "8954E749

    858F4CEEB35EBD5BFB54595B" -chunksize 40 -file  -put  -import "2. Upload HFM Actuals at Budget Rate from file" -execute -


    Absolute path to JAVA 8 or Java 11 or OpenJDK8 executable not provided. Will attempt to figure out path from JAVA_HOME o

    r Windows registry...

    Found Java executable from JAVA_HOME "E:\GMS_Anaplan\jre1.8.0_144", at E:\GMS_Anaplan\jre1.8.0_144\bin\java.exe...

    Current Java version = 1.8

    Current Java version is valid for Anaplan Connect.

    Running Anaplan Connect...

    Using Class-Path: E:\GMS_Anaplan\anaplan-connect-1-4-2\anaplan-connect-1.4.2-jar-with-dependencies.jar

    2021-05-11 10:10:10 ERROR 10072 |--   Anaplan API: Could not initialise service credentials (Runtime: The specified priv

    ateKey path 'E' is invalid)


  • Yes in an ideal setup, the Service account should be marked as a non-SSO workspace admin. @LouiseBourgonjon 

  • Hi @DaanishSoomar ,


    I changed the service account to be a workspace admin, non-SSO was already ok.

    However, we still get the same error...

  • could it be linked to the fact that I market the import as production data? (I don't think so ...?)



  • The trailing colon is required at the end of an unencrypted private key. @ben_speight, please reference the Interactive CA Certificate guide which @JonFerneau and I couathored.


    @LouiseBourgonjon - I have rewritten your Anaplan connect script for you. Can you please try the following 2 steps?


    1. Can you please edit your Anaplan Client.bat lines 123-125 to update the 3 lines to include zeros in the quotation marks highlighted below?


    Anaplan Client.PNG




    2. Can you please try using the script at the bottom? Please save this in the same folder as your AnaplanClient.bat


    set Certificate="E:\GMS_Anaplan\anaplan-connect-1-4-2\certs\AnaplanGMSCertPublickey.pem"
    set PrivateKey="E:\GMS_Anaplan\anaplan-connect-1-4-2\certs\AnaplanGMSCertPrivatekey.pem:"
    set WorkspaceId="8a81b09e603d355d016149ba8d6e67ce"
    set ModelId="8954E749858F4CEEB35EBD5BFB54595B"
    set ServiceUrl=""
    set AuthUrl=""
    set FileName="MOS_Actuals_BU_Rate.csv"
    set FilePath="E:\GMS_Anaplan\UploadtoAnaplan\MOS_Actuals_BU_Rate.csv"
    set ImportName="2. Upload HFM Actuals at Budget Rate from file"
    set ErrorDump="E:\GMS_Anaplan\UploadtoAnaplanMOS_Actuals_BU_Rate_Error.txt"
    set Chunksize=40

    set Operation= -debug -service %ServiceUrl% -auth %AuthUrl% -file %FileName% -put %FilePath% -Import Name %ImportName% -execute -output %ErrorDump%
    set Credentials=-certificate %Certificate% -pkey %PrivateKey%

    rem *** End of settings - Do not edit below this line ***

    setlocal enableextensions enabledelayedexpansion || exit /b 1
    cd %~dp0
    set Command=.\AnaplanClient.bat %Credentials% -workspace %WorkspaceId% -model %ModelId% %Operation%
    @echo %Command%
    cmd /c %Command%


    Let me know if this helps or if you still face issues.

  •  Here is the reference to colon in the guide @LouiseBourgonjon @ben_speight

    Unencrypted Private Key.PNG

  • No please see my response underneath on lower thread. @LouiseBourgonjon  this will be unrelated to Production Data.

  • Peri

    Included both the steps (#1 already we have that in our Anaplan Client.bat , #2 Used your script) , but we are still getting the same error : 





  • You're right @DaanishSoomar, I'd forgotten that.

    To get a 401 status the most likely cause is a problem with the certificate but its hard to tell what could be wrong from here.

  • Hi @DaanishSoomar ,


    Thank you for your suggestions.

    Peri and I tried the steps you mentioned, however we still face the same issue. (see log attached)

    screen shot anaplan connect test.jpg

  • Hi @LouiseBourgonjon,


    We're almost there. Do you have access to the model that is tied to the script?


    1) Can you please take a screenshot of the following:


    a) The import in the Anaplan Actions menu you wish to run (need to clarify if this is an action or process)

    b) The import data source tied to the import (you will find this in the import data sources tab next to Actions)

    c) The user in the Users tab which is associated with the script


    2) Can you please confirm you have the right model ID? I believe Anaplan is not finding the import

    "2. Upload HFM Actuals at Budget Rate from file" in the Anaplan model specified "8954E749858F4CEEB35EBD5BFB54595B"


    This could be because we are mistaking an import vs. process which have 2 different operators or we have the wrong ModelID.


    c) If these steps do not help, we may need to manually create the same Action again in Anaplan and start over.

  • Hi @DaanishSoomar ,


    Thank you for your suggestions.


    I have access to the model, see screenshots below.

    The action "2. Upload HFM Actuals at Budget Rate from file" is part of a process. In the script we try to run the action separately.





    This looks all good to me.

  • Awesome glad to help! @LouiseBourgonjon, glad we were able you find the root cause.