Skip to content
This repository has been archived by the owner on Apr 16, 2020. It is now read-only.

Rules API #24

Merged
merged 76 commits into from
Oct 5, 2016
Merged

Rules API #24

merged 76 commits into from
Oct 5, 2016

Conversation

slavcodev
Copy link
Contributor

@slavcodev slavcodev commented Apr 11, 2016

You can see docs preview here.

@slavcodev
Copy link
Contributor Author

screenshot

This was referenced Apr 11, 2016
- schedule-payment
- stop-subscriptions
active:
description: Whether rule is active
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Whether action is active, right?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yes

@creocoder
Copy link
Member

creocoder commented Apr 15, 2016

I think its OK. Not sure strict is necessary. So +1.

@slavcodev
Copy link
Contributor Author

Updated conditions

Screenshot

@slavcodev
Copy link
Contributor Author

slavcodev commented Apr 16, 2016

🔥 Please review, it is ready to merge now.

@slavcodev slavcodev force-pushed the rules branch 9 times, most recently from 4b4c705 to 692ee4f Compare April 21, 2016 13:01
@Teknologica
Copy link
Contributor

For reference, here's a criteria structure for amount === 50 || (amount !== 100 && amount > 60)

criteria: {
    operation: 'or',
    conditions: [
        {
            operation: 'and',
            conditions: [
                {
                    operation: 'not',
                    condition: {
                        operation: 'equals',
                        field: 'amount',
                        value: '100'
                    }
                },
                {
                    operation: 'gt',
                    field: 'amount',
                    value: '60'
                }
            ]
        },
        {
            operation: 'equals',
            field: 'amount',
            value: '50'
        }
    ]
}

type: string
enum:
- invoice-due-time
# TODO: Consider to change name, e.q. amountInstruction, amountPolicy
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think amountPolicy is good

slavcodev and others added 5 commits September 15, 2016 21:34
* Separate GatewayName and AcquirerName definitions
* Update GatewayAccount definition
* Modify GatewayAccountPickInstruction definition
* Fix OchaPay acquirer name
* Update EmailNotification Credential info
* Change credentialToken to credentialHash
@adamaltman
Copy link
Member

adamaltman commented Oct 5, 2016

Error: WebhookAuthorization definition already exists
    at /home/travis/build/Rebilly/RebillyAPI/node_modules/swagger-repo/lib/index.js:232:13
    at arrayReduce (/home/travis/build/Rebilly/RebillyAPI/node_modules/swagger-repo/node_modules/lodash/lodash.js:687:21)
    at Function.reduce (/home/travis/build/Rebilly/RebillyAPI/node_modules/swagger-repo/node_modules/lodash/lodash.js:9545:14)
    at globObject (/home/travis/build/Rebilly/RebillyAPI/node_modules/swagger-repo/lib/index.js:229:12)
    at globYamlObject (/home/travis/build/Rebilly/RebillyAPI/node_modules/swagger-repo/lib/index.js:240:22)
    at Object.exports.bundle (/home/travis/build/Rebilly/RebillyAPI/node_modules/swagger-repo/lib/index.js:127:27)
    at Command.<anonymous> (/home/travis/build/Rebilly/RebillyAPI/node_modules/swagger-repo/bin/swagger-repo.js:41:23)
    at Command.listener (/home/travis/build/Rebilly/RebillyAPI/node_modules/commander/index.js:301:8)
    at emitTwo (events.js:106:13)
    at Command.emit (events.js:191:7)
npm ERR! Test failed.  See above for more details.

@slavcodev slavcodev merged commit 9e9995b into master Oct 5, 2016
@slavcodev slavcodev deleted the rules branch October 5, 2016 23:51
@slavcodev
Copy link
Contributor Author

Congrats it's merged. Thanks @ALL for contributing! ✌️

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.