GSM TAP3.12 import format, RT#20767
[freeside.git] / FS / FS / cdr / gsm_tap3_12.pm
1 package FS::cdr::gsm_tap3_12;
2 use base qw( FS::cdr );
3
4 use strict;
5 use vars qw( %info );
6 use Time::Local;
7 #use Data::Dumper;
8
9 %info = (
10   'name'          => 'GSM TAP3 release 12',
11   'weight'        => 50,
12   'type'          => 'asn.1',
13   'import_fields' => [],
14   'asn_format'    => {
15     'spec'     => _asn_spec(),
16     'macro'    => 'TransferBatch', #XXX & skip the Notification ones?
17     'arrayref' => sub { shift->{'callEventDetails'}; },
18     'map'      => {
19                     'startdate'          => sub { my $callinfo = shift->{mobileOriginatedCall}{basicCallInformation};
20                                                   my $timestamp = $callinfo->{callEventStartTimeStamp};
21                                                   my $localTimeStamp = $timestamp->{localTimeStamp};
22                                                   my $utcTimeOffsetCode = $timestamp->{utcTimeOffsetCode}; #XXX not handled, utcTimeOffsetInfo in header
23                                                   $localTimeStamp =~ /^(\d{4})(\d{2})(\d{2})(\d{2})(\d{2})(\d{2})$/ or die "unparsable timestamp: $localTimeStamp\n"; #. Dumper($callinfo);
24                                                   my($year, $mon, $day, $hour, $min, $sec) = ($1, $2, $3, $4, $5, $6);
25                                                   timelocal($sec, $min, $hour, $day, $mon-1, $year);
26                                                 },
27                     'duration'           => sub { shift->{mobileOriginatedCall}{basicCallInformation}{totalCallEventDuration} },
28                     'billsec'            => sub { shift->{mobileOriginatedCall}{basicCallInformation}{totalCallEventDuration} }, #same..
29                     'src'                => sub { shift->{mobileOriginatedCall}{basicCallInformation}{chargeableSubscriber}{simChargeableSubscriber}{msisdn} },
30                     'charged_party_imsi' => sub { shift->{mobileOriginatedCall}{basicCallInformation}{chargeableSubscriber}{simChargeableSubscriber}{imsi} },
31                     'dst'                => sub { shift->{mobileOriginatedCall}{basicCallInformation}{destination}{calledNumber} }, #dialledDigits?
32                     'carrierid'          => sub { shift->{mobileOriginatedCall}{locationInformation}{networkLocation}{recEntityCode} },
33                     'userfield'          => sub { shift->{mobileOriginatedCall}{operatorSpecInformation}[0] },
34                     'servicecode'        => sub { shift->{mobileOriginatedCall}{basicServiceUsedList}[0]{basicService}{serviceCode}{teleServiceCode} },
35                     'upstream_price'     => sub { sprintf('%.5f', shift->{mobileOriginatedCall}{basicServiceUsedList}[0]{chargeInformationList}[0]{chargeDetailList}[0]{charge} / 100000 ) }, #XXX numberOfDecimalPlaces in header
36                     'calltypenum'        => sub { shift->{mobileOriginatedCall}{basicServiceUsedList}[0]{chargeInformationList}[0]{callTypeGroup}{callTypelevel1} },
37                     'quantity'           => sub { shift->{mobileOriginatedCall}{basicServiceUsedList}[0]{chargeInformationList}[0]{chargedUnits} },
38                     'quantity_able'      => sub { shift->{mobileOriginatedCall}{basicServiceUsedList}[0]{chargeInformationList}[0]{chargeableUnits} },
39                   },
40   },
41 );
42
43 sub _asn_spec {
44   <<'END';
45 --
46 --
47 -- The following ASN.1 specification defines the abstract syntax for 
48 --
49 --        Data Record Format Version 03 
50 --                           Release 12
51 --
52 -- The specification is structured as follows:
53 --   (1) structure of the Tap batch
54 --   (2) definition of the individual Tap ‘records’ 
55 --   (3) Tap data items and groups of data items used within (2)
56 --   (4) Common, non-Tap data types
57 --   (5) Tap data items for content charging
58 --
59 -- It is mainly a translation from the logical structure
60 -- diagrams. Where appropriate, names used within the 
61 -- logical structure diagrams have been shortened.
62 -- For repeating data items the name as used within the logical
63 -- structure have been extended by adding ‘list’ or ‘table’
64 -- (in some instances).
65 --
66
67
68 -- TAP-0312  DEFINITIONS IMPLICIT TAGS  ::= 
69
70 -- BEGIN 
71
72 --
73 -- Structure of a Tap batch 
74 --
75
76 DataInterChange ::= CHOICE 
77 {
78     transferBatch TransferBatch, 
79     notification  Notification,
80 ...
81 }
82
83 -- Batch Control Information must always, both logically and physically,
84 -- be the first group/item within Transfer Batch – this ensures that the
85 -- TAP release version can be readily identified.  Any new groups/items
86 -- required may be inserted at any point after Batch Control Information
87
88 TransferBatch ::= [APPLICATION 1] SEQUENCE
89 {
90     batchControlInfo       BatchControlInfo            OPTIONAL, -- *m.m.
91     accountingInfo         AccountingInfo              OPTIONAL,
92     networkInfo            NetworkInfo                 OPTIONAL, -- *m.m.
93     messageDescriptionInfo MessageDescriptionInfoList  OPTIONAL,
94     callEventDetails       CallEventDetailList         OPTIONAL, -- *m.m.
95     auditControlInfo       AuditControlInfo            OPTIONAL, -- *m.m.
96 ...
97 }
98
99 Notification ::= [APPLICATION 2] SEQUENCE
100 {
101     sender                     Sender                     OPTIONAL, -- *m.m.
102     recipient                    Recipient                  OPTIONAL, -- *m.m.
103     fileSequenceNumber           FileSequenceNumber         OPTIONAL, -- *m.m.
104     rapFileSequenceNumber        RapFileSequenceNumber      OPTIONAL,
105     fileCreationTimeStamp        FileCreationTimeStamp      OPTIONAL,
106     fileAvailableTimeStamp       FileAvailableTimeStamp     OPTIONAL, -- *m.m.
107     transferCutOffTimeStamp      TransferCutOffTimeStamp    OPTIONAL, -- *m.m.
108     specificationVersionNumber SpecificationVersionNumber OPTIONAL, -- *m.m.
109     releaseVersionNumber         ReleaseVersionNumber       OPTIONAL, -- *m.m.
110     fileTypeIndicator            FileTypeIndicator          OPTIONAL,
111     operatorSpecInformation      OperatorSpecInfoList       OPTIONAL,
112 ...
113 }
114
115 CallEventDetailList ::=  [APPLICATION 3] SEQUENCE OF CallEventDetail
116
117 CallEventDetail ::= CHOICE
118 {
119     mobileOriginatedCall   MobileOriginatedCall,
120     mobileTerminatedCall   MobileTerminatedCall,
121     supplServiceEvent      SupplServiceEvent,
122     serviceCentreUsage     ServiceCentreUsage,
123     gprsCall               GprsCall,
124     contentTransaction     ContentTransaction,
125     locationService        LocationService,
126     messagingEvent         MessagingEvent,
127     mobileSession          MobileSession,
128 ...
129 }
130
131 --
132 -- Structure of the individual Tap records
133 --
134
135 BatchControlInfo ::= [APPLICATION 4] SEQUENCE
136 {
137     sender                       Sender                         OPTIONAL, -- *m.m.
138     recipient                    Recipient                              OPTIONAL, -- *m.m.
139     fileSequenceNumber           FileSequenceNumber             OPTIONAL, -- *m.m.
140     fileCreationTimeStamp        FileCreationTimeStamp          OPTIONAL,
141     transferCutOffTimeStamp      TransferCutOffTimeStamp        OPTIONAL, -- *m.m.
142     fileAvailableTimeStamp       FileAvailableTimeStamp         OPTIONAL, -- *m.m.
143     specificationVersionNumber SpecificationVersionNumber       OPTIONAL, -- *m.m.
144     releaseVersionNumber         ReleaseVersionNumber           OPTIONAL, -- *m.m.
145     fileTypeIndicator            FileTypeIndicator              OPTIONAL,
146     rapFileSequenceNumber        RapFileSequenceNumber          OPTIONAL,
147     operatorSpecInformation      OperatorSpecInfoList           OPTIONAL,
148 ...
149 }
150
151 AccountingInfo ::= [APPLICATION 5] SEQUENCE
152 {
153     taxation                  TaxationList           OPTIONAL,
154     discounting               DiscountingList        OPTIONAL,
155     localCurrency             LocalCurrency          OPTIONAL, -- *m.m.
156     tapCurrency               TapCurrency            OPTIONAL,
157     currencyConversionInfo    CurrencyConversionList OPTIONAL,
158     tapDecimalPlaces          TapDecimalPlaces       OPTIONAL, -- *m.m.
159 ...
160 }
161
162 NetworkInfo ::= [APPLICATION 6] SEQUENCE
163 {
164     utcTimeOffsetInfo         UtcTimeOffsetInfoList OPTIONAL, -- *m.m.
165     recEntityInfo             RecEntityInfoList     OPTIONAL,
166 ...
167 }
168
169 MessageDescriptionInfoList ::= [APPLICATION 8] SEQUENCE OF MessageDescriptionInformation
170
171 MobileOriginatedCall ::= [APPLICATION 9] SEQUENCE
172 {
173     basicCallInformation    MoBasicCallInformation    OPTIONAL, -- *m.m.
174     locationInformation     LocationInformation       OPTIONAL, -- *m.m.
175     equipmentIdentifier     ImeiOrEsn                 OPTIONAL,
176     basicServiceUsedList    BasicServiceUsedList      OPTIONAL, -- *m.m.
177     supplServiceCode        SupplServiceCode          OPTIONAL,
178     thirdPartyInformation   ThirdPartyInformation     OPTIONAL,
179     camelServiceUsed        CamelServiceUsed          OPTIONAL,
180     operatorSpecInformation OperatorSpecInfoList      OPTIONAL,
181 ...
182 }    
183
184 MobileTerminatedCall ::= [APPLICATION 10] SEQUENCE
185 {
186     basicCallInformation    MtBasicCallInformation    OPTIONAL, -- *m.m.
187     locationInformation     LocationInformation       OPTIONAL, -- *m.m.
188     equipmentIdentifier     ImeiOrEsn                 OPTIONAL,
189     basicServiceUsedList    BasicServiceUsedList      OPTIONAL, -- *m.m.
190     camelServiceUsed        CamelServiceUsed          OPTIONAL,
191     operatorSpecInformation OperatorSpecInfoList      OPTIONAL,
192 ...
193 }    
194
195
196 SupplServiceEvent ::= [APPLICATION 11] SEQUENCE
197 {
198     chargeableSubscriber      ChargeableSubscriber    OPTIONAL, -- *m.m.
199     rapFileSequenceNumber     RapFileSequenceNumber   OPTIONAL,
200     locationInformation       LocationInformation     OPTIONAL, -- *m.m.
201     equipmentIdentifier       ImeiOrEsn               OPTIONAL,
202     supplServiceUsed          SupplServiceUsed        OPTIONAL, -- *m.m.
203     operatorSpecInformation   OperatorSpecInfoList    OPTIONAL,
204 ...
205 }
206
207
208 ServiceCentreUsage ::= [APPLICATION 12] SEQUENCE
209 {
210     basicInformation          ScuBasicInformation     OPTIONAL, -- *m.m.
211     rapFileSequenceNumber     RapFileSequenceNumber   OPTIONAL,
212     servingNetwork            ServingNetwork          OPTIONAL,
213     recEntityCode             RecEntityCode           OPTIONAL, -- *m.m.
214     chargeInformation         ChargeInformation       OPTIONAL, -- *m.m.
215     scuChargeType             ScuChargeType           OPTIONAL, -- *m.m.
216     scuTimeStamps             ScuTimeStamps           OPTIONAL, -- *m.m.
217     operatorSpecInformation   OperatorSpecInfoList    OPTIONAL,
218 ...
219 }
220
221 GprsCall ::= [APPLICATION 14] SEQUENCE
222 {
223     gprsBasicCallInformation  GprsBasicCallInformation  OPTIONAL, -- *m.m.
224     gprsLocationInformation   GprsLocationInformation   OPTIONAL, -- *m.m.
225     equipmentIdentifier       ImeiOrEsn                 OPTIONAL,
226     gprsServiceUsed           GprsServiceUsed           OPTIONAL, -- *m.m.
227     camelServiceUsed          CamelServiceUsed          OPTIONAL,
228     operatorSpecInformation   OperatorSpecInfoList      OPTIONAL,
229 ...
230 }
231
232 ContentTransaction ::= [APPLICATION 17] SEQUENCE
233 {
234  contentTransactionBasicInfo ContentTransactionBasicInfo OPTIONAL, -- *m.m.
235  chargedPartyInformation     ChargedPartyInformation     OPTIONAL, -- *m.m.
236  servingPartiesInformation   ServingPartiesInformation   OPTIONAL, -- *m.m.
237  contentServiceUsed          ContentServiceUsedList      OPTIONAL, -- *m.m.
238  operatorSpecInformation     OperatorSpecInfoList        OPTIONAL,
239 ...
240 }
241
242 LocationService ::= [APPLICATION 297] SEQUENCE
243 {
244     rapFileSequenceNumber         RapFileSequenceNumber       OPTIONAL,
245     recEntityCode                         RecEntityCode               OPTIONAL, -- *m.m.
246     callReference                         CallReference               OPTIONAL,
247     trackingCustomerInformation TrackingCustomerInformation OPTIONAL,
248     lCSSPInformation              LCSSPInformation            OPTIONAL,
249     trackedCustomerInformation  TrackedCustomerInformation  OPTIONAL,
250     locationServiceUsage          LocationServiceUsage        OPTIONAL, -- *m.m.
251     operatorSpecInformation       OperatorSpecInfoList        OPTIONAL,
252 ...
253 }
254
255 MessagingEvent ::= [APPLICATION 433] SEQUENCE
256 {
257     messagingEventService       MessagingEventService     OPTIONAL, -- *m.m.
258     chargedParty              ChargedParty              OPTIONAL, -- *m.m.
259     rapFileSequenceNumber       RapFileSequenceNumber     OPTIONAL,
260     simToolkitIndicator         SimToolkitIndicator       OPTIONAL,
261     geographicalLocation        GeographicalLocation      OPTIONAL,
262     eventReference            EventReference              OPTIONAL, -- *m.m.
263
264     recEntityCodeList           RecEntityCodeList         OPTIONAL, -- *m.m.  
265     networkElementList          NetworkElementList        OPTIONAL,
266     locationArea              LocationArea                OPTIONAL,
267     cellId                      CellId                            OPTIONAL,    
268     serviceStartTimestamp       ServiceStartTimestamp     OPTIONAL, -- *m.m.
269     nonChargedParty             NonChargedParty           OPTIONAL,
270     exchangeRateCode            ExchangeRateCode                  OPTIONAL,
271     callTypeGroup                       CallTypeGroup             OPTIONAL, -- *m.m.
272     charge                              Charge                    OPTIONAL, -- *m.m.
273     taxInformationList          TaxInformationList        OPTIONAL,
274     operatorSpecInformation   OperatorSpecInfoList      OPTIONAL,
275 ...
276 }
277
278 MobileSession ::= [APPLICATION 434] SEQUENCE
279 {
280     mobileSessionService        MobileSessionService      OPTIONAL, -- *m.m.
281     chargedParty              ChargedParty              OPTIONAL, -- *m.m.
282     rapFileSequenceNumber       RapFileSequenceNumber     OPTIONAL,
283     simToolkitIndicator         SimToolkitIndicator       OPTIONAL,
284     geographicalLocation        GeographicalLocation      OPTIONAL,
285     locationArea              LocationArea                OPTIONAL,
286     cellId                      CellId                            OPTIONAL,
287     eventReference            EventReference              OPTIONAL, -- *m.m.
288
289     recEntityCodeList           RecEntityCodeList         OPTIONAL, -- *m.m.
290     serviceStartTimestamp       ServiceStartTimestamp     OPTIONAL, -- *m.m.
291     causeForTerm              CauseForTerm              OPTIONAL,
292     totalCallEventDuration      TotalCallEventDuration    OPTIONAL, -- *m.m.
293     nonChargedParty             NonChargedParty           OPTIONAL,
294     sessionChargeInfoList     SessionChargeInfoList     OPTIONAL, -- *m.m.
295     operatorSpecInformation   OperatorSpecInfoList      OPTIONAL,
296 ...
297 }
298
299 AuditControlInfo ::= [APPLICATION 15] SEQUENCE
300 {
301     earliestCallTimeStamp         EarliestCallTimeStamp       OPTIONAL,
302     latestCallTimeStamp           LatestCallTimeStamp         OPTIONAL,
303     totalCharge                   TotalCharge                 OPTIONAL, -- *m.m.
304     totalChargeRefund             TotalChargeRefund           OPTIONAL,
305     totalTaxRefund                TotalTaxRefund              OPTIONAL,
306     totalTaxValue                 TotalTaxValue               OPTIONAL, -- *m.m.
307     totalDiscountValue            TotalDiscountValue          OPTIONAL, -- *m.m.
308     totalDiscountRefund           TotalDiscountRefund         OPTIONAL,
309     totalAdvisedChargeValueList TotalAdvisedChargeValueList OPTIONAL,
310     callEventDetailsCount         CallEventDetailsCount       OPTIONAL, -- *m.m.
311     operatorSpecInformation       OperatorSpecInfoList        OPTIONAL,
312 ...
313 }
314
315
316 -- 
317 -- Tap data items and groups of data items
318 --
319
320 AccessPointNameNI ::= [APPLICATION 261] AsciiString --(SIZE(1..63))
321
322 AccessPointNameOI ::= [APPLICATION 262] AsciiString --(SIZE(1..37))
323
324 ActualDeliveryTimeStamp ::= [APPLICATION 302] DateTime
325
326 AddressStringDigits ::= BCDString
327
328 AdvisedCharge ::= [APPLICATION 349] Charge
329  
330 AdvisedChargeCurrency ::= [APPLICATION 348] Currency
331  
332 AdvisedChargeInformation ::= [APPLICATION 351] SEQUENCE
333 {
334     paidIndicator         PaidIndicator         OPTIONAL,
335     paymentMethod         PaymentMethod         OPTIONAL,
336     advisedChargeCurrency AdvisedChargeCurrency OPTIONAL,
337     advisedCharge         AdvisedCharge         OPTIONAL, -- *m.m.
338     commission            Commission            OPTIONAL,
339 ...
340 }
341  
342 AgeOfLocation ::= [APPLICATION 396] INTEGER
343
344 BasicService ::= [APPLICATION 36] SEQUENCE
345 {
346     serviceCode                 BasicServiceCode       OPTIONAL, -- *m.m.
347     transparencyIndicator       TransparencyIndicator  OPTIONAL,
348     fnur                        Fnur                   OPTIONAL,
349     userProtocolIndicator       UserProtocolIndicator  OPTIONAL,
350     guaranteedBitRate           GuaranteedBitRate      OPTIONAL,
351     maximumBitRate              MaximumBitRate         OPTIONAL,
352 ...
353 }
354
355 BasicServiceCode ::= [APPLICATION 426] CHOICE 
356 {
357     teleServiceCode      TeleServiceCode,
358     bearerServiceCode    BearerServiceCode,
359 ...
360 }
361
362 BasicServiceCodeList ::= [APPLICATION 37] SEQUENCE OF BasicServiceCode
363
364 BasicServiceUsed ::= [APPLICATION 39] SEQUENCE
365 {
366     basicService                BasicService          OPTIONAL, -- *m.m.
367     chargingTimeStamp           ChargingTimeStamp     OPTIONAL,
368     chargeInformationList       ChargeInformationList OPTIONAL, -- *m.m.
369     hSCSDIndicator              HSCSDIndicator        OPTIONAL,
370 ...
371 }
372
373 BasicServiceUsedList ::= [APPLICATION 38] SEQUENCE OF BasicServiceUsed
374
375 BearerServiceCode ::= [APPLICATION 40] HexString --(SIZE(2))
376
377 EventReference ::= [APPLICATION 435]  AsciiString
378
379
380 CalledNumber ::= [APPLICATION 407] AddressStringDigits
381
382 CalledPlace ::= [APPLICATION 42] AsciiString
383
384 CalledRegion ::= [APPLICATION 46] AsciiString
385
386 CallEventDetailsCount ::= [APPLICATION 43] INTEGER 
387
388 CallEventStartTimeStamp ::= [APPLICATION 44] DateTime
389
390 CallingNumber ::= [APPLICATION 405] AddressStringDigits
391
392 CallOriginator ::= [APPLICATION 41]  SEQUENCE
393 {
394     callingNumber               CallingNumber           OPTIONAL,
395     clirIndicator               ClirIndicator         OPTIONAL,
396     sMSOriginator               SMSOriginator         OPTIONAL,
397 ...
398 }
399
400 CallReference ::= [APPLICATION 45] OCTET STRING --(SIZE(1..8))
401
402 CallTypeGroup ::= [APPLICATION 258] SEQUENCE
403 {
404     callTypeLevel1      CallTypeLevel1           OPTIONAL, -- *m.m.
405     callTypeLevel2      CallTypeLevel2           OPTIONAL, -- *m.m.
406     callTypeLevel3      CallTypeLevel3           OPTIONAL, -- *m.m.
407 ...
408 }
409
410 CallTypeLevel1 ::= [APPLICATION 259] INTEGER
411
412 CallTypeLevel2 ::= [APPLICATION 255] INTEGER
413
414 CallTypeLevel3 ::= [APPLICATION 256] INTEGER
415
416 CamelDestinationNumber ::= [APPLICATION 404] AddressStringDigits
417
418 CamelInvocationFee ::= [APPLICATION 422] AbsoluteAmount
419
420 CamelServiceKey ::= [APPLICATION 55] INTEGER
421
422 CamelServiceLevel ::= [APPLICATION 56] INTEGER
423
424 CamelServiceUsed ::= [APPLICATION 57] SEQUENCE
425 {
426     camelServiceLevel         CamelServiceLevel                 OPTIONAL,
427     camelServiceKey           CamelServiceKey                   OPTIONAL, -- *m.m.
428     defaultCallHandling       DefaultCallHandlingIndicator      OPTIONAL,
429     exchangeRateCode          ExchangeRateCode                  OPTIONAL,
430     taxInformation            TaxInformationList                OPTIONAL,
431     discountInformation       DiscountInformation               OPTIONAL,
432     camelInvocationFee        CamelInvocationFee                OPTIONAL,
433     threeGcamelDestination    ThreeGcamelDestination            OPTIONAL,
434     cseInformation            CseInformation                    OPTIONAL,
435 ...
436 }
437
438 CauseForTerm ::= [APPLICATION 58] INTEGER
439
440 CellId ::= [APPLICATION 59] INTEGER 
441
442 Charge ::= [APPLICATION 62] AbsoluteAmount
443
444 ChargeableSubscriber ::= [APPLICATION 427] CHOICE 
445 {
446     simChargeableSubscriber SimChargeableSubscriber,
447     minChargeableSubscriber MinChargeableSubscriber,
448 ...
449 }
450
451 ChargeableUnits ::= [APPLICATION 65]  INTEGER
452
453 ChargeDetail ::= [APPLICATION 63] SEQUENCE
454 {
455     chargeType              ChargeType                  OPTIONAL, -- *m.m.
456     charge                  Charge                      OPTIONAL, -- *m.m.
457     chargeableUnits         ChargeableUnits             OPTIONAL,
458     chargedUnits            ChargedUnits                OPTIONAL,
459     chargeDetailTimeStamp   ChargeDetailTimeStamp       OPTIONAL,
460 ...
461 }
462
463 ChargeDetailList ::= [APPLICATION 64] SEQUENCE OF ChargeDetail
464
465 ChargeDetailTimeStamp ::= [APPLICATION 410] ChargingTimeStamp
466
467 ChargedItem ::= [APPLICATION 66]  AsciiString --(SIZE(1))
468
469 ChargedParty ::= [APPLICATION 436] SEQUENCE
470 {
471     imsi                        Imsi                            OPTIONAL, -- *m.m.
472     msisdn                              Msisdn                  OPTIONAL,         
473     publicUserId                        PublicUserId            OPTIONAL,
474     homeBid                             HomeBid                 OPTIONAL,
475     homeLocationDescription     HomeLocationDescription OPTIONAL,
476     imei                                Imei                            OPTIONAL,
477 ...
478 }
479
480 ChargedPartyEquipment ::= [APPLICATION 323] SEQUENCE
481 {
482     equipmentIdType EquipmentIdType OPTIONAL, -- *m.m.
483     equipmentId     EquipmentId     OPTIONAL, -- *m.m.
484 ...
485 }
486  
487 ChargedPartyHomeIdentification ::= [APPLICATION 313] SEQUENCE
488 {
489     homeIdType     HomeIdType     OPTIONAL, -- *m.m.
490     homeIdentifier HomeIdentifier OPTIONAL, -- *m.m.
491 ...
492 }
493
494 ChargedPartyHomeIdList ::= [APPLICATION 314] SEQUENCE OF
495                                              ChargedPartyHomeIdentification
496
497 ChargedPartyIdentification ::= [APPLICATION 309] SEQUENCE
498 {
499     chargedPartyIdType         ChargedPartyIdType         OPTIONAL, -- *m.m.
500     chargedPartyIdentifier     ChargedPartyIdentifier     OPTIONAL, -- *m.m.
501 ...
502 }
503
504 ChargedPartyIdentifier ::= [APPLICATION 287] AsciiString
505
506 ChargedPartyIdList ::= [APPLICATION 310] SEQUENCE OF ChargedPartyIdentification
507
508 ChargedPartyIdType ::= [APPLICATION 305] INTEGER
509
510 ChargedPartyInformation ::= [APPLICATION 324] SEQUENCE
511 {
512     chargedPartyIdList       ChargedPartyIdList        OPTIONAL, -- *m.m.
513     chargedPartyHomeIdList   ChargedPartyHomeIdList    OPTIONAL,
514     chargedPartyLocationList ChargedPartyLocationList  OPTIONAL,
515     chargedPartyEquipment    ChargedPartyEquipment     OPTIONAL,
516 ...
517 }
518  
519 ChargedPartyLocation ::= [APPLICATION 320] SEQUENCE
520 {
521     locationIdType     LocationIdType     OPTIONAL, -- *m.m.
522     locationIdentifier LocationIdentifier OPTIONAL, -- *m.m.
523 ...
524 }
525  
526 ChargedPartyLocationList ::= [APPLICATION 321] SEQUENCE OF ChargedPartyLocation
527  
528 ChargedPartyStatus ::= [APPLICATION 67] INTEGER 
529
530 ChargedUnits ::= [APPLICATION 68]  INTEGER 
531
532 ChargeInformation ::= [APPLICATION 69] SEQUENCE
533 {
534     chargedItem         ChargedItem         OPTIONAL, -- *m.m.
535     exchangeRateCode    ExchangeRateCode    OPTIONAL,
536     callTypeGroup       CallTypeGroup       OPTIONAL,
537     chargeDetailList    ChargeDetailList    OPTIONAL, -- *m.m.
538     taxInformation      TaxInformationList  OPTIONAL,
539     discountInformation DiscountInformation OPTIONAL,
540 ...
541 }
542
543 ChargeInformationList ::= [APPLICATION 70] SEQUENCE OF ChargeInformation
544
545 ChargeRefundIndicator ::= [APPLICATION 344] INTEGER
546  
547 ChargeType ::= [APPLICATION 71] NumberString --(SIZE(2..3))
548
549 ChargingId ::= [APPLICATION 72] INTEGER
550
551 ChargingPoint ::= [APPLICATION 73]  AsciiString --(SIZE(1))
552
553 ChargingTimeStamp ::= [APPLICATION 74]  DateTime
554
555 ClirIndicator ::= [APPLICATION 75] INTEGER
556
557 Commission ::= [APPLICATION 350] Charge
558  
559 CompletionTimeStamp ::= [APPLICATION 76] DateTime
560
561 ContentChargingPoint ::= [APPLICATION 345] INTEGER
562  
563 ContentProvider ::= [APPLICATION 327] SEQUENCE
564 {
565     contentProviderIdType     ContentProviderIdType     OPTIONAL, -- *m.m.
566     contentProviderIdentifier ContentProviderIdentifier OPTIONAL, -- *m.m.
567 ...
568 }
569  
570 ContentProviderIdentifier ::= [APPLICATION 292] AsciiString
571
572 ContentProviderIdList ::= [APPLICATION 328] SEQUENCE OF ContentProvider
573
574 ContentProviderIdType ::= [APPLICATION 291] INTEGER
575
576 ContentProviderName ::= [APPLICATION 334] AsciiString
577  
578 ContentServiceUsed ::= [APPLICATION 352] SEQUENCE
579 {
580     contentTransactionCode       ContentTransactionCode       OPTIONAL, -- *m.m.
581     contentTransactionType       ContentTransactionType       OPTIONAL, -- *m.m.
582     objectType                   ObjectType                   OPTIONAL,
583     transactionDescriptionSupp   TransactionDescriptionSupp   OPTIONAL,
584     transactionShortDescription  TransactionShortDescription  OPTIONAL, -- *m.m.
585     transactionDetailDescription TransactionDetailDescription OPTIONAL,
586     transactionIdentifier          TransactionIdentifier        OPTIONAL, -- *m.m.
587     transactionAuthCode          TransactionAuthCode          OPTIONAL,
588     dataVolumeIncoming           DataVolumeIncoming           OPTIONAL,
589     dataVolumeOutgoing           DataVolumeOutgoing           OPTIONAL,
590     totalDataVolume              TotalDataVolume              OPTIONAL,
591     chargeRefundIndicator        ChargeRefundIndicator        OPTIONAL,
592     contentChargingPoint         ContentChargingPoint         OPTIONAL,
593     chargeInformationList        ChargeInformationList        OPTIONAL,
594     advisedChargeInformation     AdvisedChargeInformation     OPTIONAL,
595 ...
596 }
597
598 ContentServiceUsedList ::= [APPLICATION 285] SEQUENCE OF ContentServiceUsed
599  
600 ContentTransactionBasicInfo ::= [APPLICATION 304] SEQUENCE
601 {
602     rapFileSequenceNumber      RapFileSequenceNumber      OPTIONAL,
603     orderPlacedTimeStamp       OrderPlacedTimeStamp       OPTIONAL,
604     requestedDeliveryTimeStamp RequestedDeliveryTimeStamp OPTIONAL,
605     actualDeliveryTimeStamp    ActualDeliveryTimeStamp    OPTIONAL,
606     totalTransactionDuration   TotalTransactionDuration   OPTIONAL,
607     transactionStatus          TransactionStatus          OPTIONAL,
608 ...
609 }
610
611 ContentTransactionCode ::= [APPLICATION 336] INTEGER
612  
613 ContentTransactionType ::= [APPLICATION 337] INTEGER
614  
615 CseInformation ::= [APPLICATION 79] OCTET STRING --(SIZE(1..40))
616
617 CurrencyConversion ::= [APPLICATION 106] SEQUENCE
618 {
619     exchangeRateCode      ExchangeRateCode      OPTIONAL, -- *m.m.
620     numberOfDecimalPlaces NumberOfDecimalPlaces OPTIONAL, -- *m.m.
621     exchangeRate          ExchangeRate          OPTIONAL, -- *m.m.
622 ...
623 }
624
625 CurrencyConversionList ::= [APPLICATION 80] SEQUENCE OF CurrencyConversion
626
627 CustomerIdentifier ::= [APPLICATION 364] AsciiString
628
629 CustomerIdType ::= [APPLICATION 363] INTEGER
630
631 DataVolume ::= INTEGER 
632
633 DataVolumeIncoming ::= [APPLICATION 250] DataVolume
634
635 DataVolumeOutgoing ::= [APPLICATION 251] DataVolume
636
637 --
638 --  The following datatypes are used to denote timestamps.
639 --  Each timestamp consists of a local timestamp and a
640 --  corresponding UTC time offset. 
641 --  Except for the timestamps used within the Batch Control 
642 --  Information and the Audit Control Information 
643 --  the UTC time offset is identified by a code referencing
644 --  the UtcTimeOffsetInfo.
645 --  
646  
647 --
648 -- We start with the “short” datatype referencing the 
649 -- UtcTimeOffsetInfo.
650 -- 
651
652 DateTime ::= SEQUENCE 
653 {
654      -- 
655      -- Local timestamps are noted in the format
656      --
657      --     CCYYMMDDhhmmss
658      --
659      -- where CC  =  century  (‘19’, ‘20’,...)
660      --       YY  =  year     (‘00’ – ‘99’)
661      --       MM  =  month    (‘01’, ‘02’, ... , ‘12’)
662      --       DD  =  day      (‘01’, ‘02’, ... , ‘31’)
663      --       hh  =  hour     (‘00’, ‘01’, ... , ‘23’)
664      --       mm  =  minutes  (‘00’, ‘01’, ... , ‘59’)
665      --       ss  =  seconds  (‘00’, ‘01’, ... , ‘59’)
666      -- 
667     localTimeStamp     LocalTimeStamp    OPTIONAL, -- *m.m.
668     utcTimeOffsetCode  UtcTimeOffsetCode OPTIONAL, -- *m.m.
669 ...
670 }
671
672 --
673 -- The following version is the “long” datatype
674 -- containing the UTC time offset directly. 
675 --
676
677 DateTimeLong ::= SEQUENCE 
678 {
679     localTimeStamp     LocalTimeStamp OPTIONAL, -- *m.m.
680     utcTimeOffset      UtcTimeOffset  OPTIONAL, -- *m.m.
681 ...
682 }
683
684 DefaultCallHandlingIndicator ::= [APPLICATION 87] INTEGER
685
686 DepositTimeStamp ::= [APPLICATION 88] DateTime
687
688 Destination ::= [APPLICATION 89] SEQUENCE
689 {
690     calledNumber                CalledNumber            OPTIONAL,
691     dialledDigits               DialledDigits         OPTIONAL,
692     calledPlace                 CalledPlace           OPTIONAL,
693     calledRegion                CalledRegion          OPTIONAL,
694     sMSDestinationNumber        SMSDestinationNumber  OPTIONAL,
695 ...
696 }
697
698 DestinationNetwork ::= [APPLICATION 90] NetworkId 
699
700 DialledDigits ::= [APPLICATION 279] AsciiString
701
702 Discount ::= [APPLICATION 412] DiscountValue
703
704 DiscountableAmount ::= [APPLICATION 423] AbsoluteAmount
705
706 DiscountApplied ::= [APPLICATION 428] CHOICE 
707 {
708     fixedDiscountValue    FixedDiscountValue, 
709     discountRate          DiscountRate,
710 ...
711 }
712
713 DiscountCode ::= [APPLICATION 91] INTEGER
714
715 DiscountInformation ::= [APPLICATION 96] SEQUENCE
716 {
717     discountCode        DiscountCode            OPTIONAL, -- *m.m.
718     discount            Discount                OPTIONAL,
719     discountableAmount  DiscountableAmount      OPTIONAL,
720 ...
721 }
722
723 Discounting ::= [APPLICATION 94] SEQUENCE
724 {
725     discountCode    DiscountCode    OPTIONAL, -- *m.m.
726     discountApplied DiscountApplied OPTIONAL, -- *m.m.
727 ...
728 }
729
730 DiscountingList ::= [APPLICATION 95]  SEQUENCE OF Discounting
731
732 DiscountRate ::= [APPLICATION 92] PercentageRate
733
734 DiscountValue ::= AbsoluteAmount
735
736 DistanceChargeBandCode ::= [APPLICATION 98] AsciiString --(SIZE(1))
737
738 EarliestCallTimeStamp ::= [APPLICATION 101] DateTimeLong
739
740 ElementId ::= [APPLICATION 437] AsciiString
741
742 ElementType ::= [APPLICATION 438] INTEGER
743
744 EquipmentId ::= [APPLICATION 290] AsciiString
745
746 EquipmentIdType ::= [APPLICATION 322] INTEGER
747
748 Esn ::= [APPLICATION 103] NumberString
749
750 ExchangeRate ::= [APPLICATION 104] INTEGER
751
752 ExchangeRateCode ::= [APPLICATION 105] Code
753
754 FileAvailableTimeStamp ::= [APPLICATION 107] DateTimeLong
755
756 FileCreationTimeStamp ::= [APPLICATION 108] DateTimeLong
757
758 FileSequenceNumber ::= [APPLICATION 109] NumberString --(SIZE(5))
759
760 FileTypeIndicator ::= [APPLICATION 110] AsciiString --(SIZE(1))
761
762 FixedDiscountValue ::= [APPLICATION 411] DiscountValue
763
764 Fnur ::= [APPLICATION 111] INTEGER
765
766 GeographicalLocation ::= [APPLICATION 113]  SEQUENCE
767 {
768     servingNetwork              ServingNetwork                  OPTIONAL,
769     servingBid                  ServingBid                      OPTIONAL,
770     servingLocationDescription  ServingLocationDescription  OPTIONAL,
771 ...
772 }
773
774 GprsBasicCallInformation ::= [APPLICATION 114] SEQUENCE
775 {
776     gprsChargeableSubscriber    GprsChargeableSubscriber OPTIONAL, -- *m.m.
777     rapFileSequenceNumber       RapFileSequenceNumber    OPTIONAL,
778     gprsDestination             GprsDestination          OPTIONAL, -- *m.m.
779     callEventStartTimeStamp     CallEventStartTimeStamp  OPTIONAL, -- *m.m.
780     totalCallEventDuration      TotalCallEventDuration   OPTIONAL, -- *m.m.
781     causeForTerm                CauseForTerm             OPTIONAL,
782     partialTypeIndicator        PartialTypeIndicator     OPTIONAL,
783     pDPContextStartTimestamp    PDPContextStartTimestamp OPTIONAL,
784     networkInitPDPContext       NetworkInitPDPContext    OPTIONAL,
785     chargingId                  ChargingId               OPTIONAL, -- *m.m.
786 ...
787 }
788
789 GprsChargeableSubscriber ::= [APPLICATION 115] SEQUENCE
790 {
791     chargeableSubscriber        ChargeableSubscriber    OPTIONAL,
792     pdpAddress                  PdpAddress              OPTIONAL,
793     networkAccessIdentifier     NetworkAccessIdentifier OPTIONAL,
794 ...
795 }
796
797 GprsDestination ::= [APPLICATION 116] SEQUENCE
798 {
799     accessPointNameNI           AccessPointNameNI      OPTIONAL, -- *m.m.
800     accessPointNameOI           AccessPointNameOI      OPTIONAL,
801 ...
802 }
803
804 GprsLocationInformation ::= [APPLICATION 117] SEQUENCE
805 {
806     gprsNetworkLocation         GprsNetworkLocation     OPTIONAL, -- *m.m.
807     homeLocationInformation     HomeLocationInformation OPTIONAL,
808     geographicalLocation        GeographicalLocation    OPTIONAL, 
809 ...
810
811
812 GprsNetworkLocation ::= [APPLICATION 118] SEQUENCE
813 {
814     recEntity                   RecEntityCodeList OPTIONAL, -- *m.m.
815     locationArea                LocationArea      OPTIONAL,
816     cellId                      CellId            OPTIONAL,
817 ...
818 }
819
820 GprsServiceUsed ::= [APPLICATION 121]  SEQUENCE
821 {
822     iMSSignallingContext        IMSSignallingContext  OPTIONAL,
823     dataVolumeIncoming          DataVolumeIncoming    OPTIONAL, -- *m.m.
824     dataVolumeOutgoing          DataVolumeOutgoing    OPTIONAL, -- *m.m.
825     chargeInformationList       ChargeInformationList OPTIONAL, -- *m.m.
826 ...
827 }
828
829 GsmChargeableSubscriber ::= [APPLICATION 286] SEQUENCE
830 {
831     imsi     Imsi   OPTIONAL,
832     msisdn   Msisdn OPTIONAL,
833 ...
834 }
835
836 GuaranteedBitRate ::= [APPLICATION 420] OCTET STRING --(SIZE (1))
837
838 HomeBid ::= [APPLICATION 122]  Bid
839
840 HomeIdentifier ::= [APPLICATION 288] AsciiString
841
842 HomeIdType ::= [APPLICATION 311] INTEGER
843
844 HomeLocationDescription ::= [APPLICATION 413] LocationDescription
845
846 HomeLocationInformation ::= [APPLICATION 123] SEQUENCE
847 {
848     homeBid                     HomeBid                         OPTIONAL, -- *m.m.
849     homeLocationDescription     HomeLocationDescription OPTIONAL, -- *m.m.
850 ...
851 }
852
853 HorizontalAccuracyDelivered ::= [APPLICATION 392] INTEGER
854
855 HorizontalAccuracyRequested ::= [APPLICATION 385] INTEGER
856
857 HSCSDIndicator ::= [APPLICATION 424] AsciiString --(SIZE(1))
858
859 Imei ::= [APPLICATION 128] BCDString --(SIZE(7..8))
860
861 ImeiOrEsn ::= [APPLICATION 429] CHOICE 
862 {
863     imei  Imei,
864     esn   Esn,
865 ...
866
867
868 Imsi ::= [APPLICATION 129] BCDString --(SIZE(3..8))
869
870 IMSSignallingContext ::= [APPLICATION 418] INTEGER
871
872 InternetServiceProvider ::= [APPLICATION 329] SEQUENCE
873 {
874     ispIdType        IspIdType        OPTIONAL, -- *m.m.
875     ispIdentifier    IspIdentifier    OPTIONAL, -- *m.m.
876 ...
877 }
878  
879 InternetServiceProviderIdList ::= [APPLICATION 330] SEQUENCE OF InternetServiceProvider
880
881 IspIdentifier ::= [APPLICATION 294] AsciiString
882  
883 IspIdType ::= [APPLICATION 293] INTEGER
884
885 ISPList ::= [APPLICATION 378] SEQUENCE OF InternetServiceProvider
886
887 NetworkIdType ::= [APPLICATION 331] INTEGER
888
889 NetworkIdentifier ::= [APPLICATION 295] AsciiString
890
891 Network ::= [APPLICATION 332] SEQUENCE
892 {
893     networkIdType     NetworkIdType     OPTIONAL, -- *m.m.
894     networkIdentifier NetworkIdentifier OPTIONAL, -- *m.m.
895 ...
896 }
897  
898 NetworkList ::= [APPLICATION 333] SEQUENCE OF Network
899  
900 LatestCallTimeStamp ::= [APPLICATION 133] DateTimeLong
901
902 LCSQosDelivered ::= [APPLICATION 390] SEQUENCE
903 {
904     lCSTransactionStatus          LCSTransactionStatus        OPTIONAL,
905     horizontalAccuracyDelivered   HorizontalAccuracyDelivered OPTIONAL,
906     verticalAccuracyDelivered     VerticalAccuracyDelivered   OPTIONAL,
907     responseTime                  ResponseTime                OPTIONAL,
908     positioningMethod             PositioningMethod           OPTIONAL,
909     trackingPeriod                TrackingPeriod              OPTIONAL,
910     trackingFrequency             TrackingFrequency           OPTIONAL,
911     ageOfLocation                 AgeOfLocation               OPTIONAL,
912 ...
913 }
914
915 LCSQosRequested ::= [APPLICATION 383] SEQUENCE
916 {
917     lCSRequestTimestamp           LCSRequestTimestamp         OPTIONAL, -- *m.m.
918     horizontalAccuracyRequested   HorizontalAccuracyRequested OPTIONAL,
919     verticalAccuracyRequested     VerticalAccuracyRequested   OPTIONAL,
920     responseTimeCategory          ResponseTimeCategory        OPTIONAL,
921     trackingPeriod                TrackingPeriod              OPTIONAL,
922     trackingFrequency             TrackingFrequency           OPTIONAL,
923 ...
924 }
925
926 LCSRequestTimestamp ::= [APPLICATION 384] DateTime
927
928 LCSSPIdentification ::= [APPLICATION 375] SEQUENCE
929 {
930  contentProviderIdType         ContentProviderIdType     OPTIONAL, -- *m.m.
931  contentProviderIdentifier     ContentProviderIdentifier OPTIONAL, -- *m.m.
932 ...
933 }
934
935 LCSSPIdentificationList ::= [APPLICATION 374] SEQUENCE OF LCSSPIdentification
936
937 LCSSPInformation ::= [APPLICATION 373] SEQUENCE
938 {
939     lCSSPIdentificationList       LCSSPIdentificationList OPTIONAL, -- *m.m.
940     iSPList                       ISPList                 OPTIONAL,
941     networkList                   NetworkList             OPTIONAL,
942 ...
943 }
944
945 LCSTransactionStatus ::= [APPLICATION 391] INTEGER
946
947 LocalCurrency ::= [APPLICATION 135] Currency
948
949 LocalTimeStamp ::= [APPLICATION 16] NumberString --(SIZE(14))
950
951 LocationArea ::= [APPLICATION 136] INTEGER 
952
953 LocationDescription ::= AsciiString
954
955 LocationIdentifier ::= [APPLICATION 289] AsciiString
956
957 LocationIdType ::= [APPLICATION 315] INTEGER
958
959 LocationInformation ::= [APPLICATION 138]  SEQUENCE
960 {
961     networkLocation             NetworkLocation         OPTIONAL, -- *m.m.
962     homeLocationInformation     HomeLocationInformation OPTIONAL,
963     geographicalLocation        GeographicalLocation    OPTIONAL,
964 ...
965
966
967 LocationServiceUsage ::= [APPLICATION 382] SEQUENCE
968 {
969     lCSQosRequested               LCSQosRequested       OPTIONAL, -- *m.m.
970     lCSQosDelivered               LCSQosDelivered       OPTIONAL,
971     chargingTimeStamp             ChargingTimeStamp     OPTIONAL,
972     chargeInformationList         ChargeInformationList OPTIONAL, -- *m.m.
973 ...
974 }
975
976 MaximumBitRate ::= [APPLICATION 421] OCTET STRING --(SIZE (1))
977
978 Mdn ::= [APPLICATION 253] NumberString
979
980 MessageDescription ::= [APPLICATION 142] AsciiString
981
982 MessageDescriptionCode ::= [APPLICATION 141] Code
983
984 MessageDescriptionInformation ::= [APPLICATION 143] SEQUENCE
985 {
986     messageDescriptionCode MessageDescriptionCode OPTIONAL, -- *m.m.
987     messageDescription     MessageDescription     OPTIONAL, -- *m.m.
988 ...
989 }
990
991 MessageStatus ::= [APPLICATION 144] INTEGER
992
993 MessageType ::= [APPLICATION 145] INTEGER
994
995 MessagingEventService ::= [APPLICATION 439] INTEGER
996
997 Min ::= [APPLICATION 146] NumberString --(SIZE(2..15)) 
998
999 MinChargeableSubscriber ::= [APPLICATION 254] SEQUENCE
1000 {
1001     min     Min    OPTIONAL, -- *m.m.
1002     mdn     Mdn    OPTIONAL,
1003 ...
1004 }
1005
1006 MoBasicCallInformation ::= [APPLICATION 147] SEQUENCE
1007 {
1008     chargeableSubscriber        ChargeableSubscriber    OPTIONAL, -- *m.m.
1009     rapFileSequenceNumber       RapFileSequenceNumber   OPTIONAL,
1010     destination                 Destination             OPTIONAL,
1011     destinationNetwork          DestinationNetwork      OPTIONAL,
1012     callEventStartTimeStamp     CallEventStartTimeStamp OPTIONAL, -- *m.m.
1013     totalCallEventDuration      TotalCallEventDuration  OPTIONAL, -- *m.m.
1014     simToolkitIndicator         SimToolkitIndicator     OPTIONAL,
1015     causeForTerm                CauseForTerm            OPTIONAL,
1016 ...
1017 }
1018
1019 MobileSessionService ::= [APPLICATION 440] INTEGER      
1020
1021 Msisdn ::= [APPLICATION 152] BCDString --(SIZE(1..9))
1022
1023 MtBasicCallInformation ::= [APPLICATION 153] SEQUENCE
1024 {
1025     chargeableSubscriber        ChargeableSubscriber    OPTIONAL, -- *m.m.
1026     rapFileSequenceNumber       RapFileSequenceNumber   OPTIONAL,
1027     callOriginator              CallOriginator          OPTIONAL,
1028     originatingNetwork          OriginatingNetwork      OPTIONAL,
1029     callEventStartTimeStamp     CallEventStartTimeStamp OPTIONAL, -- *m.m.
1030     totalCallEventDuration      TotalCallEventDuration  OPTIONAL, -- *m.m.
1031     simToolkitIndicator         SimToolkitIndicator     OPTIONAL,
1032     causeForTerm                CauseForTerm            OPTIONAL,
1033 ...
1034 }
1035
1036 NetworkAccessIdentifier ::= [APPLICATION 417] AsciiString
1037
1038 NetworkElement ::= [APPLICATION 441]  SEQUENCE
1039 {
1040 elementType             ElementType  OPTIONAL, -- *m.m.
1041 elementId               ElementId    OPTIONAL, -- *m.m.
1042 ...
1043 }
1044
1045 NetworkElementList ::= [APPLICATION 442] SEQUENCE OF NetworkElement
1046
1047 NetworkId ::= AsciiString --(SIZE(1..6))
1048
1049 NetworkInitPDPContext ::= [APPLICATION 245] INTEGER
1050
1051 NetworkLocation ::= [APPLICATION 156]  SEQUENCE
1052 {
1053     recEntityCode               RecEntityCode OPTIONAL, -- *m.m.
1054     callReference               CallReference OPTIONAL,
1055     locationArea                LocationArea  OPTIONAL,
1056     cellId                      CellId        OPTIONAL,
1057 ...
1058 }
1059
1060 NonChargedNumber ::= [APPLICATION 402] AsciiString
1061
1062 NonChargedParty ::= [APPLICATION 443]  SEQUENCE
1063 {
1064     nonChargedPartyNumber       NonChargedPartyNumber    OPTIONAL,
1065     nonChargedPublicUserId      NonChargedPublicUserId OPTIONAL,
1066 ...
1067 }
1068
1069 NonChargedPartyNumber ::= [APPLICATION 444] AddressStringDigits
1070
1071 NonChargedPublicUserId ::= [APPLICATION 445] AsciiString 
1072
1073 NumberOfDecimalPlaces ::= [APPLICATION 159] INTEGER
1074
1075 ObjectType ::= [APPLICATION 281] INTEGER
1076
1077 OperatorSpecInfoList ::= [APPLICATION 162] SEQUENCE OF OperatorSpecInformation
1078
1079 OperatorSpecInformation ::= [APPLICATION 163] AsciiString
1080
1081 OrderPlacedTimeStamp ::= [APPLICATION 300] DateTime
1082
1083 OriginatingNetwork ::= [APPLICATION 164] NetworkId 
1084
1085 PacketDataProtocolAddress ::= [APPLICATION 165] AsciiString 
1086
1087 PaidIndicator ::= [APPLICATION 346] INTEGER
1088  
1089 PartialTypeIndicator ::=  [APPLICATION 166] AsciiString --(SIZE(1))
1090
1091 PaymentMethod ::= [APPLICATION 347] INTEGER
1092
1093 PdpAddress ::= [APPLICATION 167] PacketDataProtocolAddress
1094
1095 PDPContextStartTimestamp ::= [APPLICATION 260] DateTime
1096
1097 PlmnId ::= [APPLICATION 169] AsciiString --(SIZE(5))
1098
1099 PositioningMethod ::= [APPLICATION 395] INTEGER
1100
1101 PriorityCode ::= [APPLICATION 170] INTEGER
1102
1103 PublicUserId ::= [APPLICATION 446] AsciiString 
1104
1105 RapFileSequenceNumber ::= [APPLICATION 181]  FileSequenceNumber
1106
1107 RecEntityCode ::= [APPLICATION 184] Code
1108
1109 RecEntityCodeList ::= [APPLICATION 185] SEQUENCE OF RecEntityCode
1110
1111 RecEntityId ::= [APPLICATION 400] AsciiString
1112
1113 RecEntityInfoList ::= [APPLICATION 188] SEQUENCE OF RecEntityInformation
1114
1115 RecEntityInformation ::= [APPLICATION 183] SEQUENCE
1116 {
1117     recEntityCode  RecEntityCode OPTIONAL, -- *m.m.
1118     recEntityType  RecEntityType OPTIONAL, -- *m.m.
1119     recEntityId    RecEntityId   OPTIONAL, -- *m.m.
1120 ...
1121 }
1122  
1123 RecEntityType ::= [APPLICATION 186] INTEGER
1124
1125 Recipient ::= [APPLICATION 182]  PlmnId
1126
1127 ReleaseVersionNumber ::= [APPLICATION 189] INTEGER
1128
1129 RequestedDeliveryTimeStamp ::= [APPLICATION 301] DateTime
1130
1131 ResponseTime ::= [APPLICATION 394] INTEGER
1132
1133 ResponseTimeCategory ::= [APPLICATION 387] INTEGER
1134
1135 ScuBasicInformation ::= [APPLICATION 191] SEQUENCE
1136 {
1137     chargeableSubscriber      ScuChargeableSubscriber    OPTIONAL, -- *m.m.
1138     chargedPartyStatus        ChargedPartyStatus         OPTIONAL, -- *m.m.
1139     nonChargedNumber          NonChargedNumber           OPTIONAL, -- *m.m.
1140     clirIndicator             ClirIndicator              OPTIONAL,
1141     originatingNetwork        OriginatingNetwork         OPTIONAL,
1142     destinationNetwork        DestinationNetwork         OPTIONAL,
1143 ...
1144 }
1145
1146 ScuChargeType ::= [APPLICATION 192]  SEQUENCE
1147 {
1148     messageStatus               MessageStatus          OPTIONAL, -- *m.m.
1149     priorityCode                PriorityCode           OPTIONAL, -- *m.m.
1150     distanceChargeBandCode      DistanceChargeBandCode OPTIONAL,
1151     messageType                 MessageType            OPTIONAL, -- *m.m.
1152     messageDescriptionCode      MessageDescriptionCode OPTIONAL, -- *m.m.
1153 ...
1154 }
1155
1156 ScuTimeStamps ::= [APPLICATION 193]  SEQUENCE
1157 {
1158     depositTimeStamp            DepositTimeStamp    OPTIONAL, -- *m.m.
1159     completionTimeStamp         CompletionTimeStamp OPTIONAL, -- *m.m.
1160     chargingPoint               ChargingPoint       OPTIONAL, -- *m.m.
1161 ...
1162 }
1163
1164 ScuChargeableSubscriber ::= [APPLICATION 430] CHOICE 
1165 {
1166     gsmChargeableSubscriber    GsmChargeableSubscriber,
1167     minChargeableSubscriber    MinChargeableSubscriber,
1168 ...
1169 }
1170
1171 Sender ::= [APPLICATION 196]  PlmnId
1172
1173 ServiceStartTimestamp ::= [APPLICATION 447] DateTime
1174
1175 ServingBid ::= [APPLICATION 198]  Bid
1176
1177 ServingLocationDescription ::= [APPLICATION 414] LocationDescription
1178
1179 ServingNetwork ::= [APPLICATION 195]  AsciiString
1180
1181 ServingPartiesInformation ::= [APPLICATION 335] SEQUENCE
1182 {
1183   contentProviderName           ContentProviderName           OPTIONAL, -- *m.m.
1184   contentProviderIdList         ContentProviderIdList         OPTIONAL,
1185   internetServiceProviderIdList InternetServiceProviderIdList OPTIONAL,
1186   networkList                   NetworkList                   OPTIONAL,
1187 ...
1188 }
1189
1190 SessionChargeInfoList ::= [APPLICATION 448] SEQUENCE OF SessionChargeInformation
1191
1192 SessionChargeInformation ::= [APPLICATION 449] SEQUENCE
1193 {
1194 chargedItem                     ChargedItem              OPTIONAL, -- *m.m.    
1195 exchangeRateCode                ExchangeRateCode         OPTIONAL,
1196         callTypeGroup           CallTypeGroup            OPTIONAL, -- *m.m.
1197         chargeDetailList        ChargeDetailList         OPTIONAL, -- *m.m.
1198         taxInformationList      TaxInformationList       OPTIONAL,
1199 ...
1200 }         
1201  
1202 SimChargeableSubscriber ::= [APPLICATION 199] SEQUENCE
1203 {
1204     imsi     Imsi   OPTIONAL, -- *m.m.
1205     msisdn   Msisdn OPTIONAL,
1206 ...
1207 }
1208
1209 SimToolkitIndicator ::= [APPLICATION 200] AsciiString --(SIZE(1)) 
1210
1211 SMSDestinationNumber ::= [APPLICATION 419] AsciiString
1212
1213 SMSOriginator ::= [APPLICATION 425] AsciiString
1214
1215 SpecificationVersionNumber  ::= [APPLICATION 201] INTEGER
1216
1217 SsParameters ::= [APPLICATION 204] AsciiString --(SIZE(1..40))
1218
1219 SupplServiceActionCode ::= [APPLICATION 208] INTEGER
1220
1221 SupplServiceCode ::= [APPLICATION 209] HexString --(SIZE(2))
1222
1223 SupplServiceUsed ::= [APPLICATION 206] SEQUENCE
1224 {
1225     supplServiceCode       SupplServiceCode       OPTIONAL, -- *m.m.
1226     supplServiceActionCode SupplServiceActionCode OPTIONAL, -- *m.m.
1227     ssParameters           SsParameters           OPTIONAL,
1228     chargingTimeStamp      ChargingTimeStamp      OPTIONAL,
1229     chargeInformation      ChargeInformation      OPTIONAL,
1230     basicServiceCodeList   BasicServiceCodeList   OPTIONAL,
1231 ...
1232 }
1233
1234 TapCurrency ::= [APPLICATION 210] Currency
1235
1236 TapDecimalPlaces ::= [APPLICATION 244] INTEGER
1237
1238 TaxableAmount ::= [APPLICATION 398] AbsoluteAmount
1239
1240 Taxation ::= [APPLICATION 216] SEQUENCE
1241 {
1242     taxCode      TaxCode      OPTIONAL, -- *m.m.
1243     taxType      TaxType      OPTIONAL, -- *m.m.
1244     taxRate      TaxRate      OPTIONAL,
1245     chargeType   ChargeType   OPTIONAL,
1246     taxIndicator TaxIndicator OPTIONAL,
1247 ...
1248 }
1249
1250 TaxationList ::= [APPLICATION 211]  SEQUENCE OF Taxation
1251
1252 TaxCode ::= [APPLICATION 212] INTEGER
1253
1254 TaxIndicator ::= [APPLICATION 432] AsciiString --(SIZE(1))
1255
1256 TaxInformation ::= [APPLICATION 213] SEQUENCE
1257 {
1258     taxCode          TaxCode       OPTIONAL, -- *m.m.
1259     taxValue         TaxValue      OPTIONAL, -- *m.m.
1260     taxableAmount    TaxableAmount OPTIONAL,
1261 ...
1262 }
1263
1264 TaxInformationList ::= [APPLICATION 214]  SEQUENCE OF TaxInformation
1265
1266 -- The TaxRate item is of a fixed length to ensure that the full 5 
1267 -- decimal places is provided.
1268
1269 TaxRate ::= [APPLICATION 215] NumberString --(SIZE(7))
1270
1271 TaxType ::= [APPLICATION 217] AsciiString --(SIZE(2))
1272
1273 TaxValue ::= [APPLICATION 397] AbsoluteAmount
1274
1275 TeleServiceCode ::= [APPLICATION 218] HexString --(SIZE(2))
1276
1277 ThirdPartyInformation ::= [APPLICATION 219]  SEQUENCE
1278 {
1279     thirdPartyNumber            ThirdPartyNumber        OPTIONAL,
1280     clirIndicator               ClirIndicator         OPTIONAL,
1281 ...
1282 }
1283
1284 ThirdPartyNumber ::= [APPLICATION 403] AddressStringDigits
1285
1286 ThreeGcamelDestination ::= [APPLICATION 431] CHOICE
1287 {
1288     camelDestinationNumber    CamelDestinationNumber,
1289     gprsDestination           GprsDestination,
1290 ...
1291 }
1292
1293 TotalAdvisedCharge ::= [APPLICATION 356] AbsoluteAmount
1294  
1295 TotalAdvisedChargeRefund ::= [APPLICATION 357] AbsoluteAmount
1296  
1297 TotalAdvisedChargeValue ::= [APPLICATION 360] SEQUENCE
1298 {
1299     advisedChargeCurrency    AdvisedChargeCurrency    OPTIONAL,
1300     totalAdvisedCharge       TotalAdvisedCharge       OPTIONAL, -- *m.m.
1301     totalAdvisedChargeRefund TotalAdvisedChargeRefund OPTIONAL,
1302     totalCommission          TotalCommission          OPTIONAL,
1303     totalCommissionRefund    TotalCommissionRefund    OPTIONAL,
1304 ...
1305 }
1306  
1307 TotalAdvisedChargeValueList ::= [APPLICATION 361] SEQUENCE OF TotalAdvisedChargeValue
1308
1309 TotalCallEventDuration ::= [APPLICATION 223] INTEGER 
1310
1311 TotalCharge ::= [APPLICATION 415] AbsoluteAmount
1312
1313 TotalChargeRefund ::= [APPLICATION 355] AbsoluteAmount
1314  
1315 TotalCommission ::= [APPLICATION 358] AbsoluteAmount
1316  
1317 TotalCommissionRefund ::= [APPLICATION 359] AbsoluteAmount
1318  
1319 TotalDataVolume ::= [APPLICATION 343] DataVolume
1320  
1321 TotalDiscountRefund ::= [APPLICATION 354] AbsoluteAmount
1322  
1323 TotalDiscountValue ::= [APPLICATION 225] AbsoluteAmount
1324
1325 TotalTaxRefund ::= [APPLICATION 353] AbsoluteAmount
1326  
1327 TotalTaxValue ::= [APPLICATION 226] AbsoluteAmount
1328
1329 TotalTransactionDuration ::= [APPLICATION 416] TotalCallEventDuration
1330
1331 TrackedCustomerEquipment ::= [APPLICATION 381] SEQUENCE
1332 {
1333     equipmentIdType               EquipmentIdType OPTIONAL, -- *m.m.
1334     equipmentId                   EquipmentId     OPTIONAL, -- *m.m.
1335 ...
1336 }
1337
1338 TrackedCustomerHomeId ::= [APPLICATION 377] SEQUENCE
1339 {
1340     homeIdType                    HomeIdType     OPTIONAL, -- *m.m.
1341     homeIdentifier                HomeIdentifier OPTIONAL, -- *m.m.
1342 ...
1343 }
1344
1345 TrackedCustomerHomeIdList ::= [APPLICATION 376] SEQUENCE OF TrackedCustomerHomeId
1346
1347 TrackedCustomerIdentification ::= [APPLICATION 372] SEQUENCE
1348 {
1349     customerIdType                CustomerIdType     OPTIONAL, -- *m.m.
1350     customerIdentifier            CustomerIdentifier OPTIONAL, -- *m.m.
1351 ...
1352 }
1353
1354 TrackedCustomerIdList ::= [APPLICATION 370] SEQUENCE OF TrackedCustomerIdentification
1355
1356 TrackedCustomerInformation ::= [APPLICATION 367] SEQUENCE
1357 {
1358     trackedCustomerIdList         TrackedCustomerIdList     OPTIONAL, -- *m.m.
1359     trackedCustomerHomeIdList     TrackedCustomerHomeIdList OPTIONAL,
1360     trackedCustomerLocList        TrackedCustomerLocList    OPTIONAL,
1361     trackedCustomerEquipment      TrackedCustomerEquipment  OPTIONAL,
1362 ...
1363 }
1364
1365 TrackedCustomerLocation ::= [APPLICATION 380] SEQUENCE
1366 {
1367     locationIdType                LocationIdType     OPTIONAL, -- *m.m.
1368     locationIdentifier            LocationIdentifier OPTIONAL, -- *m.m.
1369 ...
1370 }
1371
1372 TrackedCustomerLocList ::= [APPLICATION 379] SEQUENCE OF TrackedCustomerLocation
1373
1374 TrackingCustomerEquipment ::= [APPLICATION 371] SEQUENCE
1375 {
1376     equipmentIdType               EquipmentIdType OPTIONAL, -- *m.m.
1377     equipmentId                   EquipmentId     OPTIONAL, -- *m.m.
1378 ...
1379 }
1380
1381 TrackingCustomerHomeId ::= [APPLICATION 366] SEQUENCE
1382 {
1383     homeIdType                    HomeIdType     OPTIONAL, -- *m.m.
1384     homeIdentifier                HomeIdentifier OPTIONAL, -- *m.m.
1385 ...
1386 }
1387
1388 TrackingCustomerHomeIdList ::= [APPLICATION 365] SEQUENCE OF TrackingCustomerHomeId
1389
1390 TrackingCustomerIdentification ::= [APPLICATION 362] SEQUENCE
1391 {
1392     customerIdType                CustomerIdType     OPTIONAL, -- *m.m.
1393     customerIdentifier            CustomerIdentifier OPTIONAL, -- *m.m.
1394 ...
1395 }
1396
1397 TrackingCustomerIdList ::= [APPLICATION 299] SEQUENCE OF TrackingCustomerIdentification
1398
1399 TrackingCustomerInformation ::= [APPLICATION 298] SEQUENCE
1400 {
1401     trackingCustomerIdList        TrackingCustomerIdList     OPTIONAL, -- *m.m.
1402     trackingCustomerHomeIdList    TrackingCustomerHomeIdList OPTIONAL,
1403     trackingCustomerLocList       TrackingCustomerLocList    OPTIONAL,
1404     trackingCustomerEquipment     TrackingCustomerEquipment  OPTIONAL,
1405 ...
1406 }
1407
1408 TrackingCustomerLocation ::= [APPLICATION 369] SEQUENCE
1409 {
1410     locationIdType                LocationIdType     OPTIONAL, -- *m.m.
1411     locationIdentifier            LocationIdentifier OPTIONAL, -- *m.m.
1412 ...
1413 }
1414
1415 TrackingCustomerLocList ::= [APPLICATION 368] SEQUENCE OF TrackingCustomerLocation
1416
1417 TrackingFrequency ::= [APPLICATION 389] INTEGER
1418
1419 TrackingPeriod ::= [APPLICATION 388] INTEGER
1420
1421 TransactionAuthCode ::= [APPLICATION 342] AsciiString
1422  
1423 TransactionDescriptionSupp ::= [APPLICATION 338] INTEGER
1424  
1425 TransactionDetailDescription ::= [APPLICATION 339] AsciiString
1426
1427 TransactionIdentifier ::= [APPLICATION 341] AsciiString
1428  
1429 TransactionShortDescription ::= [APPLICATION 340] AsciiString
1430  
1431 TransactionStatus ::= [APPLICATION 303] INTEGER
1432
1433 TransferCutOffTimeStamp ::= [APPLICATION 227] DateTimeLong
1434
1435 TransparencyIndicator ::= [APPLICATION 228] INTEGER
1436
1437 UserProtocolIndicator ::= [APPLICATION 280] INTEGER
1438
1439 UtcTimeOffset ::= [APPLICATION 231] AsciiString --(SIZE(5))
1440
1441 UtcTimeOffsetCode ::= [APPLICATION 232] Code
1442
1443 UtcTimeOffsetInfo ::= [APPLICATION 233] SEQUENCE
1444 {
1445     utcTimeOffsetCode   UtcTimeOffsetCode OPTIONAL, -- *m.m.
1446     utcTimeOffset       UtcTimeOffset     OPTIONAL, -- *m.m.
1447 ...
1448 }
1449
1450 UtcTimeOffsetInfoList ::= [APPLICATION 234]  SEQUENCE OF UtcTimeOffsetInfo
1451
1452 VerticalAccuracyDelivered ::= [APPLICATION 393] INTEGER
1453
1454 VerticalAccuracyRequested ::= [APPLICATION 386] INTEGER
1455
1456
1457 --
1458 -- Tagged common data types
1459 --
1460
1461 --
1462 -- The AbsoluteAmount data type is used to 
1463 -- encode absolute revenue amounts.
1464 -- The accuracy of all absolute amount values is defined
1465 -- by the value of TapDecimalPlaces within the group
1466 -- AccountingInfo for the entire TAP batch.
1467 -- Note, that only amounts greater than or equal to zero are allowed.
1468 -- The decimal number representing the amount is 
1469 -- derived from the encoded integer 
1470 -- value by division by 10^TapDecimalPlaces.
1471 -- for example for TapDecimalPlaces = 3 the following values
1472 -- will be derived:
1473 --       0   represents    0.000
1474 --      12   represents    0.012
1475 --    1234   represents    1.234
1476 -- for TapDecimalPlaces = 5 the following values will be
1477 -- derived:
1478 --       0   represents    0.00000
1479 --    1234   represents    0.01234
1480 --  123456   represents    1.23456
1481 -- This data type is used to encode (total) 
1482 -- charges, (total) discount values and 
1483 -- (total) tax values. 
1484 -- 
1485 AbsoluteAmount ::= INTEGER 
1486
1487 Bid ::=  AsciiString --(SIZE(5))
1488
1489 Code ::= INTEGER
1490
1491 --
1492 -- Non-tagged common data types
1493 --
1494 --
1495 -- Recommended common data types to be used for file encoding:
1496 --
1497 -- The following definitions should be used for TAP file creation instead of
1498 -- the default specifications (OCTET STRING)
1499 --
1500 --    AsciiString ::= VisibleString
1501 --
1502 --    Currency ::= VisibleString
1503 --
1504 --    HexString ::= VisibleString
1505 --
1506 --    NumberString ::= NumericString
1507 --
1508 --    AsciiString contains visible ISO 646 characters.
1509 --    Leading and trailing spaces must be discarded during processing.
1510 --    An AsciiString cannot contain only spaces.
1511
1512 AsciiString ::= OCTET STRING
1513
1514 --
1515 -- The BCDString data type (Binary Coded Decimal String) is used to represent
1516 -- several digits from 0 through 9, a, b, c, d, e.
1517 -- Two digits are encoded per octet.  The four leftmost bits of the octet represent
1518 -- the first digit while the four remaining bits represent the following digit.  
1519 -- A single f must be used as a filler when the total number of digits to be 
1520 -- encoded is odd.
1521 -- No other filler is allowed.
1522
1523 BCDString ::= OCTET STRING
1524
1525
1526 --
1527 -- The currency codes from ISO 4217
1528 -- are used to identify a currency 
1529 --
1530 Currency ::= OCTET STRING
1531
1532 --
1533 -- HexString contains ISO 646 characters from 0 through 9, A, B, C, D, E, F.
1534 --
1535
1536 HexString ::= OCTET STRING
1537
1538 --
1539 -- NumberString contains ISO 646 characters from 0 through 9.
1540 --
1541
1542 NumberString ::= OCTET STRING
1543
1544
1545 --
1546 -- The PercentageRate data type is used to
1547 -- encode percentage rates with an accuracy of 2 decimal places. 
1548 -- This data type is used to encode discount rates.
1549 -- The decimal number representing the percentage
1550 -- rate is obtained by dividing the integer value by 100
1551 -- Examples:
1552 --
1553 --     1500  represents  15.00 percent
1554 --     1     represents   0.01 percent
1555 --
1556 PercentageRate ::= INTEGER 
1557
1558
1559 -- END
1560 END
1561 }
1562
1563 1;