The list of codecs in the SDP is not transmitted. PJSIP

Hello!
I apologize for my English, not my native language.
I decided to switch to pjsip with the sip of the channel driver. And I ran into the following problem:
When calling to mobile numbers in Invite from Asterisk, the codec is not transmitted to sdp, the call is rejected 488 Not acceptable here. Whoever faced this problem, when sending a call to internal sdp users, the correct one is sent.
Asterisk - 14.4.0
OS: Debian 8 32bit
The channel uses PJSIP
Below is an example of a configuration:

config

[transport-udp]
bind = 0.0.0.0:5080
domain = asip.fs-pbx.ru
external_media_address = 188.166.12.74
external_signaling_address = 188.166.12.74
external_signaling_port = 5080
protocol = udp
type = transport
allow_reload = no

main-endpoint
100rel = yes
allow = alaw
allow_overlap = yes
aors = main-aors
direct_media_glare_mitigation = none
direct_media_method = invite
connected_line_method = invite
direct_media = no
disable_direct_media_on_nat = no
disallow = all
dtmf_mode = rfc4733
force_rport = yes
ice_support = yes
moh_suggest = default
rtp_ipv6 = no
rtp_symmetric = yes
send_diversion = yes
send_pai = yes
send_rpid = yes
rpid_immediate = yes
timers_min_se = 300
timers = yes
timers_sess_expires = 1800
transport = transport-udp
trust_id_inbound = yes
trust_id_outbound = yes
type = endpoint
use_ptime = yes
use_avpf = yes
force_avp = yes
media_use_received_transport = yes
inband_progress = yes
device_state_busy_at = 50
tone_zone = ru
language = ru
rtp_engine = iSIP
allow_transfer = yes
user_eq_phone = yes
moh_passthrough = no
sdp_owner = ivan
sdp_session = iSIP
allow_subscribe = yes
sub_min_expiry = 60
rtp_keepalive = 60
rtp_timeout = 600
rtp_timeout_hold = 600
asymmetric_rtp_codec = yes

[domain_alias]
type = domain_alias
domain = asip.fs-pbx.ru

main-aor
default_expiration = 1800
maximum_expiration = 3600
max_contacts = 0
minimum_expiration = 60
remove_existing = no
type = aor
qualify_frequency = 0
qualify_timeout = 3.0
authenticate_qualify = no

[system]
timer_t1 = 500
timer_b = 32000
compact_headers = no
threadpool_initial_size = 0
threadpool_auto_increment = 5
threadpool_idle_timeout = 60
threadpool_max_size = 0
disable_tcp_switch = yes
type = system

[global]
max_forwards = 70
keep_alive_interval = 60
contact_expiration_check_interval = 30
disable_multi_domain = no
max_initial_qualify_time = 0
unidentified_request_period = 5
unidentified_request_count = 5
unidentified_request_prune_interval = 30
type = global
user_agent = iSIP
debug = off

; sip provider
[login-zdm]
type = registration
transport = transport-udp
outbound_auth=login-zdm-auth
server_uri=sip:sip.zadarma.com
client_uri=sip:login@sip.zadarma.com
retry_interval=60
expiration=300
contact_user=login

[login-zdm-auth]
auth_type = userpass
nonce_lifetime = 32
username = login
password = password
type = auth

login-zdm
type = aor
contact = sip:sip.zadarma.com

login-zdm
type = endpoint
context = main-in
outbound_auth = login-zdm-auth
aors = login-zdm
from_user = login
from_domain = sip.zadarma.com
transport = transport-udp

[login-zdm]
type = identify
endpoint = login-zdm
match = sip.zadarma.com

;local user
[200]
type = endpoint
disallow = all
allow = alaw
rtp_symmetric=yes
force_rport=yes
transport = transport-udp
context = tula_out
auth = 200
aors = 200

[200]
type = auth
auth_type = userpass
username = login
password = password

200
type = aor
max_contacts = 10

[300]
type = endpoint
disallow = all
allow = alaw
transport = transport-udp
rtp_symmetric=yes
force_rport=yes
context = tula_out
auth = 300
aors = 300

[300]
type = auth
auth_type = userpass
username = login
password = password

300
type = aor
max_contacts = 10

INVITE sip:+79190812016@sip.zadarma.com;user=phone SIP/2.0
Via: SIP/2.0/UDP 188.166.12.74:5080;rport;branch=z9hG4bKPjbebd2561-160d-4f4b-a200-f7649eb2e6bb
From: sip:531305@sip.zadarma.com;user=phone;tag=a8c71f95-cc85-452c-8100-e7bc04ec6233
To: sip:+79190812016@sip.zadarma.com;user=phone
Contact: sip:531305@188.166.12.74:5080
Call-ID: 216e7252-0d91-4c91-9b09-6256c83c71b2
CSeq: 30033 INVITE
Allow: OPTIONS, SUBSCRIBE, NOTIFY, PUBLISH, INVITE, ACK, BYE, CANCEL, UPDATE, PRACK, REGISTER, MESSAGE, REFER
Supported: 100rel, timer, replaces, norefersub
Session-Expires: 1800
Min-SE: 300
Max-Forwards: 70
User-Agent: iSIP
[truncated]Proxy-Authorization: Digest username=“531305”, realm=“sip.zadarma.com”, nonce=“WQbBI1kGv/e9KUFQbebvQdq24q8kEOJ0”, uri="sip:+79190812016@sip.zadarma.com;user=phone", response=“801a7ac43b6708cfc71fa1d17c017da7”, cnonce="4160b725-
P-Asserted-Identity: sip:200@sip.zadarma.com;user=phone
Remote-Party-ID: sip:200@sip.zadarma.com;user=phone;privacy=off;screen=no
Content-Type: application/sdp
Content-Length: 69

v=0  
o=ivan 135552881 135552881 IN IP4 188.166.12.74  
s=iSIP  
t=0 0  

SIP/2.0 488 Not acceptable here
Via: SIP/2.0/UDP 188.166.12.74:5080;received=188.166.12.74;rport=5080;branch=z9hG4bKPjbebd2561-160d-4f4b-a200-f7649eb2e6bb
From: sip:531305@sip.zadarma.com;user=phone;tag=a8c71f95-cc85-452c-8100-e7bc04ec6233
To: sip:+79190812016@sip.zadarma.com;user=phone;tag=as654f140c
Call-ID: 216e7252-0d91-4c91-9b09-6256c83c71b2
CSeq: 30033 INVITE
Server: Zadarma Voip
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO, PUBLISH, MESSAGE
Supported: replaces
Content-Length: 0

And here dump pcap https://yadi.sk/d/lv6HE9gr3HWEa6
Tell me what could be the problem?

You must mark logs as preformatted text for them to be useful here!

You have not provided a configuration; you have provided logs. [It turns out that the configuration is there, but hidden by default; you have to click on the triangle.]

Neither party in the log is using a default Asterisk User-Agent value, so which is Asterisk?

Asterisk has no concept of mobile versus local numbers, so please explain how your configuration differs, apart from the actual digits dialled.

Your configuration is such that there will be no codecs offered. You have “allow=ulaw” followed by “disallow=all” which would disallow all codecs. Ordering in the config section matters, the “disallow=all” needs to be before the “allow=ulaw”.