rinkleton

Well-Known Member
Jul 16, 2015
116
6
68
Cleveland
cPanel Access Level
Root Administrator
Also, I'm looking into the UAPI functions... what I think are the equivalent ones... But if I run:
EmailAuth::disable_dkim
Then
EmailAuth::ensure_dkim_keys_exist
EmailAuth::validate_current_dkims

The latter two seem to indicate that DKIM is still installed even though the disable function runs successfully.
EmailAuth::ensure_dkim_keys_exist - reports "status" is "1" and "msg" is "key is acceptable"
EmailAuth::validate_current_dkims - reports no "error" but "state" is " MISMATCH" - I'm guessing this one is validating against the actual resolved value DNS value for DKIM, not the DNS entry entered on this server.

What I'm trying to do is check whether the DNS entry has been added to this server, whether or not it's DNS is actually being used.
 

cPRex

Jurassic Moderator
Staff member
Oct 19, 2014
12,498
1,971
363
cPanel Access Level
Root Administrator
Hey there! While the functions still exist, we don't recommend using anything from cPanel API 2 at this point. Those tools should get updated to the UAPI system.

The old documentation is still present here:


but ideall you'd get things up and running with newer calls available here:

 

rinkleton

Well-Known Member
Jul 16, 2015
116
6
68
Cleveland
cPanel Access Level
Root Administrator
If they still exist, why am I getting the errors:
Could not find function 'installed' in module 'DKIMUI'
Could not find function 'installed' in module 'SPFUI'

I've been using them for years without any issues.

Hey there! While the functions still exist, we don't recommend using anything from cPanel API 2 at this point. Those tools should get updated to the UAPI system.
 

cPRex

Jurassic Moderator
Staff member
Oct 19, 2014
12,498
1,971
363
cPanel Access Level
Root Administrator
I just tested all the DKIMUI options available on a version 106 machine and they all give me the "could not find function" error so it appears those are indeed removed at this point.

The closest thing I have available would be this command:


as if the key validates, it would also have to be installed.

There are also several other DKIm API calls in our EmailAuth section here: Email DNS Settings
 

rinkleton

Well-Known Member
Jul 16, 2015
116
6
68
Cleveland
cPanel Access Level
Root Administrator
I would be nice if the legacy docs could be updated to reflect this. Is there is a list of removed API functions somewhere? I checked the release notes for the past few versions and don't see any reference to these.
 

cPRex

Jurassic Moderator
Staff member
Oct 19, 2014
12,498
1,971
363
cPanel Access Level
Root Administrator
Update - it sounds like the current plan is to actually restore the DKIMUI API functionality because their isn't a UAPI equivalent available. It would still be a good idea to get things moved over to newer tools, but you will likely get the DKIMUI functions back in a future release. I'm not sure exactly when that will happen yet as this announcement just happened.
 

rinkleton

Well-Known Member
Jul 16, 2015
116
6
68
Cleveland
cPanel Access Level
Root Administrator
That's great. I still use a lot of the cpanel2 APIs because they don't have UAPI equivelants. I check back every so often so see if they are there, but it's been years with no changes. I'm afraid one day the cpanel2 APIs will disappear like this and I'll be stuck. I mostly use the domain management APIs (AddonDomain, Park, SubDomain). I know there has been some improvements with how those are handled, so I expected a delay in the APIs to get them right. But I use some others like Cron, MysqlFE, and CustInfo. I don't believe those have had much change so I expected to see them have UAPI functions.